Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

HID: roccat: Fix "cannot create duplicate filename" problems

Fixing some wrong macro stringification/concatenation.

Acked-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Signed-off-by: Stefan Achatz <erazor_de@users.sourceforge.net>
Signed-off-by: Jiri Kosina <jkosina@suse.cz>

authored by

Stefan Achatz and committed by
Jiri Kosina
550dbf47 19872d20

+7 -7
+1 -1
drivers/hid/hid-roccat-kone.c
··· 382 382 } 383 383 #define PROFILE_ATTR(number) \ 384 384 static struct bin_attribute bin_attr_profile##number = { \ 385 - .attr = { .name = "profile##number", .mode = 0660 }, \ 385 + .attr = { .name = "profile" #number, .mode = 0660 }, \ 386 386 .size = sizeof(struct kone_profile), \ 387 387 .read = kone_sysfs_read_profilex, \ 388 388 .write = kone_sysfs_write_profilex, \
+2 -2
drivers/hid/hid-roccat-koneplus.c
··· 229 229 230 230 #define PROFILE_ATTR(number) \ 231 231 static struct bin_attribute bin_attr_profile##number##_settings = { \ 232 - .attr = { .name = "profile##number##_settings", .mode = 0440 }, \ 232 + .attr = { .name = "profile" #number "_settings", .mode = 0440 }, \ 233 233 .size = KONEPLUS_SIZE_PROFILE_SETTINGS, \ 234 234 .read = koneplus_sysfs_read_profilex_settings, \ 235 235 .private = &profile_numbers[number-1], \ 236 236 }; \ 237 237 static struct bin_attribute bin_attr_profile##number##_buttons = { \ 238 - .attr = { .name = "profile##number##_buttons", .mode = 0440 }, \ 238 + .attr = { .name = "profile" #number "_buttons", .mode = 0440 }, \ 239 239 .size = KONEPLUS_SIZE_PROFILE_BUTTONS, \ 240 240 .read = koneplus_sysfs_read_profilex_buttons, \ 241 241 .private = &profile_numbers[number-1], \
+2 -2
drivers/hid/hid-roccat-kovaplus.c
··· 257 257 258 258 #define PROFILE_ATTR(number) \ 259 259 static struct bin_attribute bin_attr_profile##number##_settings = { \ 260 - .attr = { .name = "profile##number##_settings", .mode = 0440 }, \ 260 + .attr = { .name = "profile" #number "_settings", .mode = 0440 }, \ 261 261 .size = KOVAPLUS_SIZE_PROFILE_SETTINGS, \ 262 262 .read = kovaplus_sysfs_read_profilex_settings, \ 263 263 .private = &profile_numbers[number-1], \ 264 264 }; \ 265 265 static struct bin_attribute bin_attr_profile##number##_buttons = { \ 266 - .attr = { .name = "profile##number##_buttons", .mode = 0440 }, \ 266 + .attr = { .name = "profile" #number "_buttons", .mode = 0440 }, \ 267 267 .size = KOVAPLUS_SIZE_PROFILE_BUTTONS, \ 268 268 .read = kovaplus_sysfs_read_profilex_buttons, \ 269 269 .private = &profile_numbers[number-1], \
+2 -2
drivers/hid/hid-roccat-pyra.c
··· 225 225 226 226 #define PROFILE_ATTR(number) \ 227 227 static struct bin_attribute bin_attr_profile##number##_settings = { \ 228 - .attr = { .name = "profile##number##_settings", .mode = 0440 }, \ 228 + .attr = { .name = "profile" #number "_settings", .mode = 0440 }, \ 229 229 .size = PYRA_SIZE_PROFILE_SETTINGS, \ 230 230 .read = pyra_sysfs_read_profilex_settings, \ 231 231 .private = &profile_numbers[number-1], \ 232 232 }; \ 233 233 static struct bin_attribute bin_attr_profile##number##_buttons = { \ 234 - .attr = { .name = "profile##number##_buttons", .mode = 0440 }, \ 234 + .attr = { .name = "profile" #number "_buttons", .mode = 0440 }, \ 235 235 .size = PYRA_SIZE_PROFILE_BUTTONS, \ 236 236 .read = pyra_sysfs_read_profilex_buttons, \ 237 237 .private = &profile_numbers[number-1], \