Commit 4ecc7317 authored by Dmitry Torokhov's avatar Dmitry Torokhov
Browse files

Input: atkbd - switch to use scnprintf() to suppress truncation warning



Switch the driver to use scnprintf() to avoid warnings about potential
truncation of "phys" field which we can tolerate.

Reported-by: default avatarAndy Shevchenko <andriy.shevchenko@linux.intel.com>
Signed-off-by: default avatarDmitry Torokhov <dmitry.torokhov@gmail.com>
parent 05286c5d
Loading
Loading
Loading
Loading
+2 −2
Original line number Diff line number Diff line
@@ -1191,7 +1191,7 @@ static void atkbd_set_device_attrs(struct atkbd *atkbd)
			 "AT %s Set %d keyboard",
			 atkbd->translated ? "Translated" : "Raw", atkbd->set);

	snprintf(atkbd->phys, sizeof(atkbd->phys),
	scnprintf(atkbd->phys, sizeof(atkbd->phys),
		  "%s/input0", atkbd->ps2dev.serio->phys);

	input_dev->name = atkbd->name;