staging: fbtft: convert sysfs attributes to use ATTRIBUTE_GROUPS
Subsystems (2)
PATCH v3 1/1 staging: fbtft: convert sysfs attributes to use ATTRIBUTE_GROUPS
Replace direct device_create_file() calls with the correct ATTRIBUTE_GROUPS() macro. Add fbtft_groups as dev_groups in the driver structure so the driver core automatically adds and removes the sysfs attributes when a device is bound or unbound.
---
v3: Remove stray blank line in fbtft_attrs[] array
v2: - Use DEVICE_ATTR_RW() macro instead of DEVICE_ATTR()
- Move DEVICE_ATTR_RW() definitions closer to their callbacks
- Remove trailing comma after NULL in attribute array
- Remove extern declaration from internal.h, not needed
- Use ATTRIBUTE_GROUPS() macro and add dev_groups to driver structure as suggested by Greg KH and Andy Shevchenko
- Compile tested with: make M=drivers/staging/fbtft modules
drivers/staging/fbtft/fbtft-core.c | 3 -- drivers/staging/fbtft/fbtft-sysfs.c | 81 +++++++++++------------------ drivers/staging/fbtft/fbtft.h | 2 + drivers/staging/fbtft/internal.h | 2 - 4 files changed, 32 insertions(+), 56 deletions(-)
drivers/staging/fbtft/fbtft-core.c +0 -3
@@ -782,8 +782,6 @@ int fbtft_register_framebuffer(struct fb_info *fb_info)if (ret <0 ) goto reg_fail; -fbtft_sysfs_init (par); -if (par->txbuf.buf && par->txbuf.len >=1024 )sprintf (text1,", %zu KiB buffer memory" , par->txbuf.len >>10 );if (spi)
@@ -826,7 +824,6 @@ int fbtft_unregister_framebuffer(struct fb_info *fb_info)if (par->fbtftops.unregister_backlight) par->fbtftops.unregister_backlight (par); -fbtft_sysfs_exit (par);unregister_framebuffer (fb_info);return 0 ;
drivers/staging/fbtft/fbtft-sysfs.c +30 -51
104 lines not on this page · raw message
drivers/staging/fbtft/fbtft.h +2 -0
@@ -299,6 +299,7 @@ static struct spi_driver fbtft_driver_spi_driver = { \ .driver = { \ .name = _name, \ .of_match_table = dt_ids, \ + .dev_groups = fbtft_groups, \ }, \ .id_table = _spi_ids, \ .probe = fbtft_driver_probe_spi, \
@@ -328,6 +329,7 @@ static struct platform_driver fbtft_driver_platform_driver = { \ .name = _name, \ .owner = THIS_MODULE, \ .of_match_table = dt_ids, \ + .dev_groups = fbtft_groups, \ }, \ .probe = fbtft_driver_probe_pdev, \ .remove = fbtft_driver_remove_pdev, \
drivers/staging/fbtft/internal.h +0 -2
@@ -4,8 +4,6 @@#ifndef __LINUX_FBTFT_INTERNAL_H#define __LINUX_FBTFT_INTERNAL_H -void fbtft_sysfs_init (struct fbtft_par *par); -void fbtft_sysfs_exit (struct fbtft_par *par);void fbtft_expand_debug_value (unsigned long *debug);int fbtft_gamma_parse_str (struct fbtft_par *par,u32 *curves,const char *str,int size);
Signature · 1 line
2.53.0
Quoted 4 lines · Harshit Shaw
Replace direct
device_create_file()calls with the correctATTRIBUTE_GROUPS()macro. Addfbtft_groupsasdev_groupsin the driver structure so the driver core automatically adds and removes the sysfs attributes when a device is bound or unbound.
You ignored my tag (why?!) and what about Sashiko review? Did it pass?
Signature · 2 lines
With Best Regards, Andy Shevchenko
kernel test robot
build botkernel test robot noticed the following build errors:
Hi Harshit,
kernel test robot noticed the following build errors:
[auto build test ERROR on staging/staging-testing]
url: https://github.com/intel-lab-lkp/linux/commits/Harshit-Shaw/staging-fbtft-convert-sysfs-attributes-to-use-ATTRIBUTE_GROUPS/20260513-044051 base: staging/staging-testing patch link: https://lore.kernel.org/r/20260512200104.19002-1-shawharshit116%40gmail.com patch subject: [PATCH v3] staging: fbtft: convert sysfs attributes to use ATTRIBUTE_GROUPS config: powerpc64-randconfig-002-20260513 (https://download.01.org/0day-ci/archive/20260513/[email protected]/config) compiler: clang version 23.0.0git (https://github.com/llvm/llvm-project 5bac06718f502014fade905512f1d26d578a18f3) reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20260513/[email protected]/reproduce)
If you fix the issue in a separate patch/commit (i.e. not just a new version of the same patch/commit), kindly add following tags
| Reported-by: kernel test robot <[email protected]>
| Closes: https://lore.kernel.org/oe-kbuild-all/[email protected]/
All errors (new ones prefixed by >>):
drivers/staging/fbtft/fb_ssd1305.c:198:1: error: use of undeclared identifier 'fbtft_groups'; did you mean 'set_groups'?
198 | FBTFT_REGISTER_DRIVER(DRVNAME, "solomon,ssd1305", &display);
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
drivers/staging/fbtft/fbtft.h:323:13: note: expanded from macro 'FBTFT_REGISTER_DRIVER'
323 | \
| ^
324 | FBTFT_SPI_DRIVER(_name, _compatible, _display, NULL) \
| ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
drivers/staging/fbtft/fbtft.h:301:17: note: expanded from macro '\
FBTFT_SPI_DRIVER'
301 | .dev_groups = fbtft_groups, \
| ^~~~~~~~~~~~
include/linux/cred.h:70:13: note: 'set_groups' declared here
70 | extern void set_groups(struct cred *, struct group_info *);
| ^
>> drivers/staging/fbtft/fb_ssd1305.c:198:1: error: incompatible pointer types initializing 'const struct attribute_group **' with an expression of type 'void (struct cred *, struct group_info *)' [-Wincompatible-pointer-types]
198 | FBTFT_REGISTER_DRIVER(DRVNAME, "solomon,ssd1305", &display);
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
drivers/staging/fbtft/fbtft.h:323:13: note: expanded from macro 'FBTFT_REGISTER_DRIVER'
323 | \
| ^
324 | FBTFT_SPI_DRIVER(_name, _compatible, _display, NULL) \
| ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
drivers/staging/fbtft/fbtft.h:301:17: note: expanded from macro '\
FBTFT_SPI_DRIVER'
301 | .dev_groups = fbtft_groups, \
| ^~~~~~~~~~~~
drivers/staging/fbtft/fb_ssd1305.c:198:1: error: use of undeclared identifier 'fbtft_groups'; did you mean 'set_groups'?
198 | FBTFT_REGISTER_DRIVER(DRVNAME, "solomon,ssd1305", &display);
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
drivers/staging/fbtft/fbtft.h:331:17: note: expanded from macro 'FBTFT_REGISTER_DRIVER'
331 | .dev_groups = fbtft_groups, \
| ^~~~~~~~~~~~
include/linux/cred.h:70:13: note: 'set_groups' declared here
70 | extern void set_groups(struct cred *, struct group_info *);
| ^
>> drivers/staging/fbtft/fb_ssd1305.c:198:1: error: incompatible pointer types initializing 'const struct attribute_group **' with an expression of type 'void (struct cred *, struct group_info *)' [-Wincompatible-pointer-types]
198 | FBTFT_REGISTER_DRIVER(DRVNAME, "solomon,ssd1305", &display);
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
drivers/staging/fbtft/fbtft.h:331:17: note: expanded from macro 'FBTFT_REGISTER_DRIVER'
331 | .dev_groups = fbtft_groups, \
| ^~~~~~~~~~~~
4 errors generated.
--
drivers/staging/fbtft/fb_upd161704.c:175:1: error: use of undeclared identifier 'fbtft_groups'; did you mean 'set_groups'?
175 | FBTFT_REGISTER_DRIVER(DRVNAME, "nec,upd161704", &display);
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
drivers/staging/fbtft/fbtft.h:323:13: note: expanded from macro 'FBTFT_REGISTER_DRIVER'
323 | \
| ^
324 | FBTFT_SPI_DRIVER(_name, _compatible, _display, NULL) \
| ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
drivers/staging/fbtft/fbtft.h:301:17: note: expanded from macro '\
FBTFT_SPI_DRIVER'
301 | .dev_groups = fbtft_groups, \
| ^~~~~~~~~~~~
include/linux/cred.h:70:13: note: 'set_groups' declared here
70 | extern void set_groups(struct cred *, struct group_info *);
| ^
>> drivers/staging/fbtft/fb_upd161704.c:175:1: error: incompatible pointer types initializing 'const struct attribute_group **' with an expression of type 'void (struct cred *, struct group_info *)' [-Wincompatible-pointer-types]
175 | FBTFT_REGISTER_DRIVER(DRVNAME, "nec,upd161704", &display);
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
drivers/staging/fbtft/fbtft.h:323:13: note: expanded from macro 'FBTFT_REGISTER_DRIVER'
323 | \
| ^
324 | FBTFT_SPI_DRIVER(_name, _compatible, _display, NULL) \
| ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
drivers/staging/fbtft/fbtft.h:301:17: note: expanded from macro '\
FBTFT_SPI_DRIVER'
301 | .dev_groups = fbtft_groups, \
| ^~~~~~~~~~~~
drivers/staging/fbtft/fb_upd161704.c:175:1: error: use of undeclared identifier 'fbtft_groups'; did you mean 'set_groups'?
175 | FBTFT_REGISTER_DRIVER(DRVNAME, "nec,upd161704", &display);
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
drivers/staging/fbtft/fbtft.h:331:17: note: expanded from macro 'FBTFT_REGISTER_DRIVER'
331 | .dev_groups = fbtft_groups, \
| ^~~~~~~~~~~~
include/linux/cred.h:70:13: note: 'set_groups' declared here
70 | extern void set_groups(struct cred *, struct group_info *);
| ^
>> drivers/staging/fbtft/fb_upd161704.c:175:1: error: incompatible pointer types initializing 'const struct attribute_group **' with an expression of type 'void (struct cred *, struct group_info *)' [-Wincompatible-pointer-types]
175 | FBTFT_REGISTER_DRIVER(DRVNAME, "nec,upd161704", &display);
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
drivers/staging/fbtft/fbtft.h:331:17: note: expanded from macro 'FBTFT_REGISTER_DRIVER'
331 | .dev_groups = fbtft_groups, \
| ^~~~~~~~~~~~
4 errors generated.
--
drivers/staging/fbtft/fb_tls8204.c:153:1: error: use of undeclared identifier 'fbtft_groups'; did you mean 'set_groups'?
153 | FBTFT_REGISTER_DRIVER(DRVNAME, "teralane,tls8204", &display);
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
drivers/staging/fbtft/fbtft.h:323:13: note: expanded from macro 'FBTFT_REGISTER_DRIVER'
323 | \
| ^
324 | FBTFT_SPI_DRIVER(_name, _compatible, _display, NULL) \
| ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
drivers/staging/fbtft/fbtft.h:301:17: note: expanded from macro '\
FBTFT_SPI_DRIVER'
301 | .dev_groups = fbtft_groups, \
| ^~~~~~~~~~~~
include/linux/cred.h:70:13: note: 'set_groups' declared here
70 | extern void set_groups(struct cred *, struct group_info *);
| ^
>> drivers/staging/fbtft/fb_tls8204.c:153:1: error: incompatible pointer types initializing 'const struct attribute_group **' with an expression of type 'void (struct cred *, struct group_info *)' [-Wincompatible-pointer-types]
153 | FBTFT_REGISTER_DRIVER(DRVNAME, "teralane,tls8204", &display);
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
drivers/staging/fbtft/fbtft.h:323:13: note: expanded from macro 'FBTFT_REGISTER_DRIVER'
323 | \
| ^
324 | FBTFT_SPI_DRIVER(_name, _compatible, _display, NULL) \
| ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
drivers/staging/fbtft/fbtft.h:301:17: note: expanded from macro '\
FBTFT_SPI_DRIVER'
301 | .dev_groups = fbtft_groups, \
| ^~~~~~~~~~~~
drivers/staging/fbtft/fb_tls8204.c:153:1: error: use of undeclared identifier 'fbtft_groups'; did you mean 'set_groups'?
153 | FBTFT_REGISTER_DRIVER(DRVNAME, "teralane,tls8204", &display);
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
drivers/staging/fbtft/fbtft.h:331:17: note: expanded from macro 'FBTFT_REGISTER_DRIVER'
331 | .dev_groups = fbtft_groups, \
| ^~~~~~~~~~~~
include/linux/cred.h:70:13: note: 'set_groups' declared here
70 | extern void set_groups(struct cred *, struct group_info *);
| ^
>> drivers/staging/fbtft/fb_tls8204.c:153:1: error: incompatible pointer types initializing 'const struct attribute_group **' with an expression of type 'void (struct cred *, struct group_info *)' [-Wincompatible-pointer-types]
153 | FBTFT_REGISTER_DRIVER(DRVNAME, "teralane,tls8204", &display);
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
drivers/staging/fbtft/fbtft.h:331:17: note: expanded from macro 'FBTFT_REGISTER_DRIVER'
331 | .dev_groups = fbtft_groups, \
| ^~~~~~~~~~~~
4 errors generated.
--
drivers/staging/fbtft/fb_ili9341.c:136:1: error: use of undeclared identifier 'fbtft_groups'; did you mean 'set_groups'?
136 | FBTFT_REGISTER_SPI_DRIVER(DRVNAME, "ilitek", "ili9341", &display);
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
drivers/staging/fbtft/fbtft.h:368:11: note: expanded from macro 'FBTFT_REGISTER_SPI_DRIVER'
368 | \
| ^
369 | FBTFT_SPI_DRIVER(_name, _comp_vend "," _comp_dev, _display, spi_ids) \
| ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
drivers/staging/fbtft/fbtft.h:301:17: note: expanded from macro '\
FBTFT_SPI_DRIVER'
301 | .dev_groups = fbtft_groups, \
| ^~~~~~~~~~~~
include/linux/cred.h:70:13: note: 'set_groups' declared here
70 | extern void set_groups(struct cred *, struct group_info *);
| ^
>> drivers/staging/fbtft/fb_ili9341.c:136:1: error: incompatible pointer types initializing 'const struct attribute_group **' with an expression of type 'void (struct cred *, struct group_info *)' [-Wincompatible-pointer-types]
136 | FBTFT_REGISTER_SPI_DRIVER(DRVNAME, "ilitek", "ili9341", &display);
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
drivers/staging/fbtft/fbtft.h:368:11: note: expanded from macro 'FBTFT_REGISTER_SPI_DRIVER'
368 | \
| ^
369 | FBTFT_SPI_DRIVER(_name, _comp_vend "," _comp_dev, _display, spi_ids) \
| ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
drivers/staging/fbtft/fbtft.h:301:17: note: expanded from macro '\
FBTFT_SPI_DRIVER'
301 | .dev_groups = fbtft_groups, \
| ^~~~~~~~~~~~
2 errors generated.
--
drivers/staging/fbtft/fb_st7735r.c:165:1: error: use of undeclared identifier 'fbtft_groups'; did you mean 'set_groups'?
165 | FBTFT_REGISTER_DRIVER(DRVNAME, "sitronix,st7735r", &display);
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
drivers/staging/fbtft/fbtft.h:323:13: note: expanded from macro 'FBTFT_REGISTER_DRIVER'
323 | \
| ^
324 | FBTFT_SPI_DRIVER(_name, _compatible, _display, NULL) \
| ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
drivers/staging/fbtft/fbtft.h:301:17: note: expanded from macro '\
FBTFT_SPI_DRIVER'
301 | .dev_groups = fbtft_groups, \
| ^~~~~~~~~~~~
include/linux/cred.h:70:13: note: 'set_groups' declared here
70 | extern void set_groups(struct cred *, struct group_info *);
| ^
>> drivers/staging/fbtft/fb_st7735r.c:165:1: error: incompatible pointer types initializing 'const struct attribute_group **' with an expression of type 'void (struct cred *, struct group_info *)' [-Wincompatible-pointer-types]
165 | FBTFT_REGISTER_DRIVER(DRVNAME, "sitronix,st7735r", &display);
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
drivers/staging/fbtft/fbtft.h:323:13: note: expanded from macro 'FBTFT_REGISTER_DRIVER'
323 | \
| ^
324 | FBTFT_SPI_DRIVER(_name, _compatible, _display, NULL) \
| ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
drivers/staging/fbtft/fbtft.h:301:17: note: expanded from macro '\
FBTFT_SPI_DRIVER'
301 | .dev_groups = fbtft_groups, \
| ^~~~~~~~~~~~
drivers/staging/fbtft/fb_st7735r.c:165:1: error: use of undeclared identifier 'fbtft_groups'; did you mean 'set_groups'?
165 | FBTFT_REGISTER_DRIVER(DRVNAME, "sitronix,st7735r", &display);
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
drivers/staging/fbtft/fbtft.h:331:17: note: expanded from macro 'FBTFT_REGISTER_DRIVER'
331 | .dev_groups = fbtft_groups, \
| ^~~~~~~~~~~~
include/linux/cred.h:70:13: note: 'set_groups' declared here
70 | extern void set_groups(struct cred *, struct group_info *);
| ^
>> drivers/staging/fbtft/fb_st7735r.c:165:1: error: incompatible pointer types initializing 'const struct attribute_group **' with an expression of type 'void (struct cred *, struct group_info *)' [-Wincompatible-pointer-types]
165 | FBTFT_REGISTER_DRIVER(DRVNAME, "sitronix,st7735r", &display);
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
drivers/staging/fbtft/fbtft.h:331:17: note: expanded from macro 'FBTFT_REGISTER_DRIVER'
331 | .dev_groups = fbtft_groups, \
| ^~~~~~~~~~~~
4 errors generated.
--
drivers/staging/fbtft/fb_hx8357d.c:178:1: error: use of undeclared identifier 'fbtft_groups'; did you mean 'set_groups'?
178 | FBTFT_REGISTER_DRIVER(DRVNAME, "himax,hx8357d", &display);
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
drivers/staging/fbtft/fbtft.h:323:13: note: expanded from macro 'FBTFT_REGISTER_DRIVER'
323 | \
| ^
324 | FBTFT_SPI_DRIVER(_name, _compatible, _display, NULL) \
| ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
drivers/staging/fbtft/fbtft.h:301:17: note: expanded from macro '\
FBTFT_SPI_DRIVER'
301 | .dev_groups = fbtft_groups, \
| ^~~~~~~~~~~~
include/linux/cred.h:70:13: note: 'set_groups' declared here
70 | extern void set_groups(struct cred *, struct group_info *);
| ^
>> drivers/staging/fbtft/fb_hx8357d.c:178:1: error: incompatible pointer types initializing 'const struct attribute_group **' with an expression of type 'void (struct cred *, struct group_info *)' [-Wincompatible-pointer-types]
178 | FBTFT_REGISTER_DRIVER(DRVNAME, "himax,hx8357d", &display);
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
drivers/staging/fbtft/fbtft.h:323:13: note: expanded from macro 'FBTFT_REGISTER_DRIVER'
323 | \
| ^
324 | FBTFT_SPI_DRIVER(_name, _compatible, _display, NULL) \
| ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
drivers/staging/fbtft/fbtft.h:301:17: note: expanded from macro '\
FBTFT_SPI_DRIVER'
301 | .dev_groups = fbtft_groups, \
| ^~~~~~~~~~~~
drivers/staging/fbtft/fb_hx8357d.c:178:1: error: use of undeclared identifier 'fbtft_groups'; did you mean 'set_groups'?
178 | FBTFT_REGISTER_DRIVER(DRVNAME, "himax,hx8357d", &display);
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
drivers/staging/fbtft/fbtft.h:331:17: note: expanded from macro 'FBTFT_REGISTER_DRIVER'
331 | .dev_groups = fbtft_groups, \
| ^~~~~~~~~~~~
include/linux/cred.h:70:13: note: 'set_groups' declared here
70 | extern void set_groups(struct cred *, struct group_info *);
| ^
>> drivers/staging/fbtft/fb_hx8357d.c:178:1: error: incompatible pointer types initializing 'const struct attribute_group **' with an expression of type 'void (struct cred *, struct group_info *)' [-Wincompatible-pointer-types]
178 | FBTFT_REGISTER_DRIVER(DRVNAME, "himax,hx8357d", &display);
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
drivers/staging/fbtft/fbtft.h:331:17: note: expanded from macro 'FBTFT_REGISTER_DRIVER'
331 | .dev_groups = fbtft_groups, \
| ^~~~~~~~~~~~
4 errors generated.
--
drivers/staging/fbtft/fb_hx8347d.c:174:1: error: use of undeclared identifier 'fbtft_groups'; did you mean 'set_groups'?
174 | FBTFT_REGISTER_DRIVER(DRVNAME, "himax,hx8347d", &display);
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
drivers/staging/fbtft/fbtft.h:323:13: note: expanded from macro 'FBTFT_REGISTER_DRIVER'
323 | \
| ^
324 | FBTFT_SPI_DRIVER(_name, _compatible, _display, NULL) \
| ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
drivers/staging/fbtft/fbtft.h:301:17: note: expanded from macro '\
FBTFT_SPI_DRIVER'
301 | .dev_groups = fbtft_groups, \
| ^~~~~~~~~~~~
include/linux/cred.h:70:13: note: 'set_groups' declared here
70 | extern void set_groups(struct cred *, struct group_info *);
| ^
>> drivers/staging/fbtft/fb_hx8347d.c:174:1: error: incompatible pointer types initializing 'const struct attribute_group **' with an expression of type 'void (struct cred *, struct group_info *)' [-Wincompatible-pointer-types]
174 | FBTFT_REGISTER_DRIVER(DRVNAME, "himax,hx8347d", &display);
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
drivers/staging/fbtft/fbtft.h:323:13: note: expanded from macro 'FBTFT_REGISTER_DRIVER'
323 | \
| ^
324 | FBTFT_SPI_DRIVER(_name, _compatible, _display, NULL) \
| ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
drivers/staging/fbtft/fbtft.h:301:17: note: expanded from macro '\
FBTFT_SPI_DRIVER'
301 | .dev_groups = fbtft_groups, \
| ^~~~~~~~~~~~
drivers/staging/fbtft/fb_hx8347d.c:174:1: error: use of undeclared identifier 'fbtft_groups'; did you mean 'set_groups'?
174 | FBTFT_REGISTER_DRIVER(DRVNAME, "himax,hx8347d", &display);
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
drivers/staging/fbtft/fbtft.h:331:17: note: expanded from macro 'FBTFT_REGISTER_DRIVER'
331 | .dev_groups = fbtft_groups, \
| ^~~~~~~~~~~~
include/linux/cred.h:70:13: note: 'set_groups' declared here
70 | extern void set_groups(struct cred *, struct group_info *);
| ^
>> drivers/staging/fbtft/fb_hx8347d.c:174:1: error: incompatible pointer types initializing 'const struct attribute_group **' with an expression of type 'void (struct cred *, struct group_info *)' [-Wincompatible-pointer-types]
174 | FBTFT_REGISTER_DRIVER(DRVNAME, "himax,hx8347d", &display);
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
drivers/staging/fbtft/fbtft.h:331:17: note: expanded from macro 'FBTFT_REGISTER_DRIVER'
331 | .dev_groups = fbtft_groups, \
| ^~~~~~~~~~~~
4 errors generated.
--
drivers/staging/fbtft/fb_uc1611.c:325:1: error: use of undeclared identifier 'fbtft_groups'; did you mean 'set_groups'?
325 | FBTFT_REGISTER_DRIVER(DRVNAME, "ultrachip,uc1611", &display);
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
drivers/staging/fbtft/fbtft.h:323:13: note: expanded from macro 'FBTFT_REGISTER_DRIVER'
323 | \
| ^
324 | FBTFT_SPI_DRIVER(_name, _compatible, _display, NULL) \
| ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
drivers/staging/fbtft/fbtft.h:301:17: note: expanded from macro '\
FBTFT_SPI_DRIVER'
301 | .dev_groups = fbtft_groups, \
| ^~~~~~~~~~~~
include/linux/cred.h:70:13: note: 'set_groups' declared here
70 | extern void set_groups(struct cred *, struct group_info *);
| ^
>> drivers/staging/fbtft/fb_uc1611.c:325:1: error: incompatible pointer types initializing 'const struct attribute_group **' with an expression of type 'void (struct cred *, struct group_info *)' [-Wincompatible-pointer-types]
325 | FBTFT_REGISTER_DRIVER(DRVNAME, "ultrachip,uc1611", &display);
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
drivers/staging/fbtft/fbtft.h:323:13: note: expanded from macro 'FBTFT_REGISTER_DRIVER'
323 | \
| ^
324 | FBTFT_SPI_DRIVER(_name, _compatible, _display, NULL) \
| ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
drivers/staging/fbtft/fbtft.h:301:17: note: expanded from macro '\
FBTFT_SPI_DRIVER'
301 | .dev_groups = fbtft_groups, \
| ^~~~~~~~~~~~
drivers/staging/fbtft/fb_uc1611.c:325:1: error: use of undeclared identifier 'fbtft_groups'; did you mean 'set_groups'?
325 | FBTFT_REGISTER_DRIVER(DRVNAME, "ultrachip,uc1611", &display);
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
drivers/staging/fbtft/fbtft.h:331:17: note: expanded from macro 'FBTFT_REGISTER_DRIVER'
331 | .dev_groups = fbtft_groups, \
| ^~~~~~~~~~~~
include/linux/cred.h:70:13: note: 'set_groups' declared here
70 | extern void set_groups(struct cred *, struct group_info *);
| ^
>> drivers/staging/fbtft/fb_uc1611.c:325:1: error: incompatible pointer types initializing 'const struct attribute_group **' with an expression of type 'void (struct cred *, struct group_info *)' [-Wincompatible-pointer-types]
325 | FBTFT_REGISTER_DRIVER(DRVNAME, "ultrachip,uc1611", &display);
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
drivers/staging/fbtft/fbtft.h:331:17: note: expanded from macro 'FBTFT_REGISTER_DRIVER'
331 | .dev_groups = fbtft_groups, \
| ^~~~~~~~~~~~ 4 errors generated.
..
vim +198 drivers/staging/fbtft/fb_ssd1305.c
5795354f75132a Alexey Mednyy 2016-01-27 1975795354f75132a Alexey Mednyy 2016-01-27 @198 FBTFT_REGISTER_DRIVER(DRVNAME, "solomon,ssd1305", &display); 5795354f75132a Alexey Mednyy 2016-01-27 199
Signature · 2 lines
0-DAY CI Kernel Test Service https://github.com/intel/lkp-tests/wiki