View Issue Details

IDProjectCategoryView StatusLast Update
0018225CentOS-7-OTHERpublic2021-06-14 18:24
Reporterflfq Assigned To 
PrioritynormalSeveritymajorReproducibilityalways
Status closedResolutionwon't fix 
Platformx86_64OScentosOS Versioncentos 7
Product Version7.9.2009 
Summary0018225: gadget usb network can't build
Descriptiongadget usb network can't build
Steps To Reproduce[user@host]$ mkdir -p ~/rpmbuild/{BUILD,BUILDROOT,RPMS,SOURCES,SPECS,SRPMS}
[user@host]$ echo '%_topdir %(echo $HOME)/rpmbuild' > ~/.rpmmacros
[root@host]# yum install asciidoc audit-libs-devel bash bc binutils binutils-devel bison diffutils elfutils
[root@host]# yum install elfutils-devel elfutils-libelf-devel findutils flex gawk gcc gettext gzip hmaccalc hostname java-devel
[root@host]# yum install m4 make module-init-tools ncurses-devel net-tools newt-devel numactl-devel openssl
[root@host]# yum install patch pciutils-devel perl perl-ExtUtils-Embed pesign python-devel python-docutils redhat-rpm-config
[root@host]# yum install rpm-build sh-utils tar xmlto xz zlib-devel
[root@host]# rpm -i https://vault.centos.org/7.9.2009/updates/Source/SPackages/kernel-3.10.0-1160.25.1.el7.src.rpm 2>&1 | grep -v exist
[user@host]$ cd ~/rpmbuild/SPECS
[user@host SPECS]$ rpmbuild -bp --target=$(uname -m) kernel.spec
[root@localhost ~]# cd ~/rpmbuild/BUILD/kernel-3.10.0-1160.25.1.el7/linux-3.10.0-1160.25.1.el7.centos.plus.x86_64/
[root@localhost ~]# make menuconfig

    Device Drivers --->
    [*] USB support --->
    <M> USB Gadget Support --->
    USB Gadget Drivers
     <M> Ethernet Gadget (with CDC Ethernet support)
     [*] RNDIS support


[root@localhost ~]# make
Additional InformationCC [M] drivers/usb/gadget/configfs.o
drivers/usb/gadget/configfs.c:605:3: error: ‘gadget_config_name_configuration’ undeclared here (not in a function)
  &gadget_config_name_configuration.attr,
   ^
drivers/usb/gadget/configfs.c:710:3: error: ‘gadget_strings_manufacturer’ undeclared here (not in a function)
  &gadget_strings_manufacturer.attr,
   ^
drivers/usb/gadget/configfs.c:710:30: error: request for member ‘attr’ in something not a structure or union
  &gadget_strings_manufacturer.attr,
                              ^
drivers/usb/gadget/configfs.c:710:2: error: initializer element is not constant
  &gadget_strings_manufacturer.attr,
  ^
drivers/usb/gadget/configfs.c:710:2: error: (near initialization for ‘gadget_strings_langid_attrs[0]’)
drivers/usb/gadget/configfs.c:711:3: error: ‘gadget_strings_product’ undeclared here (not in a function)
  &gadget_strings_product.attr,
   ^
drivers/usb/gadget/configfs.c:711:25: error: request for member ‘attr’ in something not a structure or union
  &gadget_strings_product.attr,
                         ^
drivers/usb/gadget/configfs.c:711:2: error: initializer element is not constant
  &gadget_strings_product.attr,
  ^
drivers/usb/gadget/configfs.c:711:2: error: (near initialization for ‘gadget_strings_langid_attrs[1]’)
drivers/usb/gadget/configfs.c:712:3: error: ‘gadget_strings_serialnumber’ undeclared here (not in a function)
  &gadget_strings_serialnumber.attr,
   ^
drivers/usb/gadget/configfs.c:712:30: error: request for member ‘attr’ in something not a structure or union
  &gadget_strings_serialnumber.attr,
                              ^
drivers/usb/gadget/configfs.c:712:2: error: initializer element is not constant
  &gadget_strings_serialnumber.attr,
  ^
drivers/usb/gadget/configfs.c:712:2: error: (near initialization for ‘gadget_strings_langid_attrs[2]’)
In file included from drivers/usb/gadget/configfs.c:1:0:
drivers/usb/gadget/configfs.c:602:15: error: ‘gadget_config_name_attr_configuration’ defined but not used [-Werror=unused-variable]
 GS_STRINGS_RW(gadget_config_name, configuration);
               ^
include/linux/configfs.h:140:34: note: in definition of macro ‘CONFIGFS_ATTR’
 static struct configfs_attribute _pfx##attr_##_name = { \
                                  ^
drivers/usb/gadget/configfs.c:602:1: note: in expansion of macro ‘GS_STRINGS_RW’
 GS_STRINGS_RW(gadget_config_name, configuration);
 ^
drivers/usb/gadget/configfs.c:705:15: error: ‘gadget_strings_attr_manufacturer’ defined but not used [-Werror=unused-variable]
 GS_STRINGS_RW(gadget_strings, manufacturer);
               ^
include/linux/configfs.h:140:34: note: in definition of macro ‘CONFIGFS_ATTR’
 static struct configfs_attribute _pfx##attr_##_name = { \
                                  ^
drivers/usb/gadget/configfs.c:705:1: note: in expansion of macro ‘GS_STRINGS_RW’
 GS_STRINGS_RW(gadget_strings, manufacturer);
 ^
drivers/usb/gadget/configfs.c:706:15: error: ‘gadget_strings_attr_product’ defined but not used [-Werror=unused-variable]
 GS_STRINGS_RW(gadget_strings, product);
               ^
include/linux/configfs.h:140:34: note: in definition of macro ‘CONFIGFS_ATTR’
 static struct configfs_attribute _pfx##attr_##_name = { \
                                  ^
drivers/usb/gadget/configfs.c:706:1: note: in expansion of macro ‘GS_STRINGS_RW’
 GS_STRINGS_RW(gadget_strings, product);
 ^
drivers/usb/gadget/configfs.c:707:15: error: ‘gadget_strings_attr_serialnumber’ defined but not used [-Werror=unused-variable]
 GS_STRINGS_RW(gadget_strings, serialnumber);
               ^
include/linux/configfs.h:140:34: note: in definition of macro ‘CONFIGFS_ATTR’
 static struct configfs_attribute _pfx##attr_##_name = { \
                                  ^
drivers/usb/gadget/configfs.c:707:1: note: in expansion of macro ‘GS_STRINGS_RW’
 GS_STRINGS_RW(gadget_strings, serialnumber);
 ^
cc1: all warnings being treated as errors
make[3]: *** [drivers/usb/gadget/configfs.o] Error 1
make[2]: *** [drivers/usb/gadget] Error 2
make[1]: *** [drivers/usb] Error 2
make: *** [drivers] Error 2
Tagsgadget usb netwrok
abrt_hash
URL

Activities

TrevorH

TrevorH

2021-06-14 18:24

manager   ~0038496

Sorry but building your own kernels doesn't mean you get to raise bug reports about it. If it's broken, it just means you get to keep all the pieces.

Issue History

Date Modified Username Field Change
2021-06-14 18:17 flfq New Issue
2021-06-14 18:17 flfq Tag Attached: gadget usb netwrok
2021-06-14 18:24 TrevorH Status new => closed
2021-06-14 18:24 TrevorH Resolution open => won't fix
2021-06-14 18:24 TrevorH Note Added: 0038496