[rmk-arm:cex7 160/170] drivers/bus/fsl-mc/fsl-mc-bus.c:1111:39: error: implicit declaration of function 'iommu_get_dma_domain'; did you mean 'iommu_is_dma_domain'?
by kernel test robot
tree: git://git.armlinux.org.uk/~rmk/linux-arm cex7
head: cdfacabed5a40f44a694e4254ef37fcb4fee1e62
commit: 9d9cfaf6528a80634c1aa12d94112e3adb05bdbb [160/170] bus: fsl-mc: add IOMMU mappings for MC firmware and DCFG
config: arm-randconfig-r004-20220119 (https://download.01.org/0day-ci/archive/20220120/202201200604.v1t4HdLH-lk...)
compiler: arm-linux-gnueabi-gcc (GCC) 11.2.0
reproduce (this is a W=1 build):
wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
chmod +x ~/bin/make.cross
git remote add rmk-arm git://git.armlinux.org.uk/~rmk/linux-arm
git fetch --no-tags rmk-arm cex7
git checkout 9d9cfaf6528a80634c1aa12d94112e3adb05bdbb
# save the config file to linux build tree
mkdir build_dir
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-11.2.0 make.cross O=build_dir ARCH=arm SHELL=/bin/bash drivers/bus/fsl-mc/
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp(a)intel.com>
All error/warnings (new ones prefixed by >>):
drivers/bus/fsl-mc/fsl-mc-bus.c: In function 'fsl_mc_setup_iommu':
>> drivers/bus/fsl-mc/fsl-mc-bus.c:1111:39: error: implicit declaration of function 'iommu_get_dma_domain'; did you mean 'iommu_is_dma_domain'? [-Werror=implicit-function-declaration]
1111 | struct iommu_domain *domain = iommu_get_dma_domain(dev);
| ^~~~~~~~~~~~~~~~~~~~
| iommu_is_dma_domain
>> drivers/bus/fsl-mc/fsl-mc-bus.c:1111:39: warning: initialization of 'struct iommu_domain *' from 'int' makes pointer from integer without a cast [-Wint-conversion]
cc1: some warnings being treated as errors
vim +1111 drivers/bus/fsl-mc/fsl-mc-bus.c
1108
1109 static void fsl_mc_setup_iommu(struct device *dev, struct fsl_mc *mc)
1110 {
> 1111 struct iommu_domain *domain = iommu_get_dma_domain(dev);
1112 struct resource dcfg_res = DEFINE_RES_MEM(0x01e00000, 0x10000);
1113 struct device_node *np;
1114 u64 firmware_base;
1115 u64 mc_ram_base;
1116 u32 mc_ram_size;
1117 u32 mcfbalr;
1118 u32 mcfbahr;
1119 int ret;
1120
1121 if (!domain) {
1122 dev_err(dev, "Missing IOMMU domain - MC firmware will crash\n");
1123 return;
1124 }
1125
1126 mcfbalr = readl(mc->fsl_mc_regs + FSL_MC_FBALR);
1127 mcfbahr = readl(mc->fsl_mc_regs + FSL_MC_FBAHR);
1128
1129 firmware_base = mcfbalr & MCFBAR_LOW;
1130 firmware_base |= (u64)(mcfbahr & MCFBAR_HIGH) << 32;
1131
1132 /* Calculate the size of MC RAM. */
1133 mc_ram_size = mcfbalr & MCFBAR_MEMSZ;
1134 if (mc_ram_size != 255)
1135 mc_ram_size = (mc_ram_size + 1) * SZ_256M;
1136 else
1137 mc_ram_size = SZ_128M;
1138
1139 /*
1140 * Calculate base address of MC RAM. U-Boot says:
1141 * "As per MC design document, MC initial base address should be least
1142 * significant 512MB address of MC private memory, i.e. address should
1143 * point to end address masked with 512MB offset in private DRAM block."
1144 * and uses the following calculation:
1145 *
1146 * (gd->arch.resv_ram + mc_ram_size - 1) &
1147 * MC_RAM_BASE_ADDR_ALIGNMENT_MASK
1148 *
1149 * where gd->arch.resv_ram is the start of the MC reserved RAM block,
1150 * and is itself aligned to 512MB.
1151 *
1152 * Hence, if the reserved RAM starts at 0x2780000000 and is 0x70000000
1153 * in size, then the firmware address will be 0x27e0000000. However,
1154 * if it is 512M, then the reserved RAM and the firmware base addresses
1155 * will be identical.
1156 */
1157 mc_ram_base = ALIGN(firmware_base - mc_ram_size + 1, SZ_512M);
1158
1159 /*
1160 * Give MC firmware access to the MC RAM, which includes the MC
1161 * firmware image itself.
1162 */
1163 ret = iommu_map(domain, mc_ram_base, mc_ram_base, mc_ram_size,
1164 IOMMU_CACHE | IOMMU_WRITE | IOMMU_READ);
1165 if (ret)
1166 dev_err(dev, "Failed to setup IOMMU mapping for MC RAM: %pe\n",
1167 ERR_PTR(ret));
1168
1169 /* Give firmware access to the DCFG so it can read the SVR register */
1170 np = of_find_compatible_node(NULL, NULL, "fsl,lx2160a-dcfg");
1171 if (np) {
1172 ret = of_address_to_resource(np, 0, &dcfg_res);
1173 if (ret) {
1174 dev_err(dev, "Failed to get dcfg resource: %pe\n",
1175 ERR_PTR(ret));
1176 return;
1177 }
1178 } else {
1179 dev_warn(dev,
1180 "Failed to find dcfg node - using default addresses\n");
1181 }
1182
1183 ret = iommu_map(domain, dcfg_res.start, dcfg_res.start,
1184 resource_size(&dcfg_res), IOMMU_READ);
1185 if (ret)
1186 dev_err(dev, "Failed to setup IOMMU mapping for DCFG: %pe\n",
1187 ERR_PTR(ret));
1188 }
1189
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
8 months
mm/gup.c:1674:16: error: unexpected token, expected comma
by kernel test robot
tree: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
head: 1d1df41c5a33359a00e919d54eaebfb789711fdc
commit: bb523b406c849eef8f265a07cd7f320f1f177743 gup: Turn fault_in_pages_{readable,writeable} into fault_in_{readable,writeable}
date: 3 months ago
config: mips-randconfig-r003-20220118 (https://download.01.org/0day-ci/archive/20220120/202201200528.F5X9Vnfb-lk...)
compiler: clang version 14.0.0 (https://github.com/llvm/llvm-project 5f782d25a742302d25ef3c8b84b54f7483c2deb9)
reproduce (this is a W=1 build):
wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
chmod +x ~/bin/make.cross
# install mips cross compiling tool for clang build
# apt-get install binutils-mips-linux-gnu
# https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit...
git remote add linus https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
git fetch --no-tags linus master
git checkout bb523b406c849eef8f265a07cd7f320f1f177743
# save the config file to linux build tree
mkdir build_dir
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross W=1 O=build_dir ARCH=mips SHELL=/bin/bash
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp(a)intel.com>
All errors (new ones prefixed by >>):
>> mm/gup.c:1674:16: error: unexpected token, expected comma
if (unlikely(__put_user(0, uaddr) != 0))
^
arch/mips/include/asm/uaccess.h:171:18: note: expanded from macro '__put_user'
__put_data_asm(user_sb, __pu_ptr); \
^
<inline asm>:3:10: note: instantiated into assembly here
.set eva
^
>> mm/gup.c:1674:16: error: invalid operand for instruction
if (unlikely(__put_user(0, uaddr) != 0))
^
arch/mips/include/asm/uaccess.h:171:18: note: expanded from macro '__put_user'
__put_data_asm(user_sb, __pu_ptr); \
^
<inline asm>:4:10: note: instantiated into assembly here
sbe $0, 0($17)
^
mm/gup.c:1682:16: error: unexpected token, expected comma
if (unlikely(__put_user(0, uaddr) != 0))
^
arch/mips/include/asm/uaccess.h:171:18: note: expanded from macro '__put_user'
__put_data_asm(user_sb, __pu_ptr); \
^
<inline asm>:3:10: note: instantiated into assembly here
.set eva
^
mm/gup.c:1682:16: error: invalid operand for instruction
if (unlikely(__put_user(0, uaddr) != 0))
^
arch/mips/include/asm/uaccess.h:171:18: note: expanded from macro '__put_user'
__put_data_asm(user_sb, __pu_ptr); \
^
<inline asm>:4:10: note: instantiated into assembly here
sbe $0, 0($2)
^
mm/gup.c:1710:16: error: unexpected token, expected comma
if (unlikely(__get_user(c, uaddr) != 0))
^
arch/mips/include/asm/uaccess.h:218:23: note: expanded from macro '__get_user'
__get_data_asm((x), user_lb, __gu_ptr); \
^
<inline asm>:3:10: note: instantiated into assembly here
.set eva
^
mm/gup.c:1710:16: error: invalid operand for instruction
if (unlikely(__get_user(c, uaddr) != 0))
^
arch/mips/include/asm/uaccess.h:218:23: note: expanded from macro '__get_user'
__get_data_asm((x), user_lb, __gu_ptr); \
^
<inline asm>:4:10: note: instantiated into assembly here
lbe $3, 0($17)
^
mm/gup.c:1718:16: error: unexpected token, expected comma
if (unlikely(__get_user(c, uaddr) != 0))
^
arch/mips/include/asm/uaccess.h:218:23: note: expanded from macro '__get_user'
__get_data_asm((x), user_lb, __gu_ptr); \
^
<inline asm>:3:10: note: instantiated into assembly here
.set eva
^
mm/gup.c:1718:16: error: invalid operand for instruction
if (unlikely(__get_user(c, uaddr) != 0))
^
arch/mips/include/asm/uaccess.h:218:23: note: expanded from macro '__get_user'
__get_data_asm((x), user_lb, __gu_ptr); \
^
<inline asm>:4:10: note: instantiated into assembly here
lbe $5, 0($2)
^
8 errors generated.
vim +1674 mm/gup.c
1658
1659 /**
1660 * fault_in_writeable - fault in userspace address range for writing
1661 * @uaddr: start of address range
1662 * @size: size of address range
1663 *
1664 * Returns the number of bytes not faulted in (like copy_to_user() and
1665 * copy_from_user()).
1666 */
1667 size_t fault_in_writeable(char __user *uaddr, size_t size)
1668 {
1669 char __user *start = uaddr, *end;
1670
1671 if (unlikely(size == 0))
1672 return 0;
1673 if (!PAGE_ALIGNED(uaddr)) {
> 1674 if (unlikely(__put_user(0, uaddr) != 0))
1675 return size;
1676 uaddr = (char __user *)PAGE_ALIGN((unsigned long)uaddr);
1677 }
1678 end = (char __user *)PAGE_ALIGN((unsigned long)start + size);
1679 if (unlikely(end < start))
1680 end = NULL;
1681 while (uaddr != end) {
1682 if (unlikely(__put_user(0, uaddr) != 0))
1683 goto out;
1684 uaddr += PAGE_SIZE;
1685 }
1686
1687 out:
1688 if (size > uaddr - start)
1689 return size - (uaddr - start);
1690 return 0;
1691 }
1692 EXPORT_SYMBOL(fault_in_writeable);
1693
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
8 months
include/linux/compiler_types.h:319:45: error: call to '__compiletime_assert_242' declared with attribute error: BUILD_BUG_ON failed: FIX_KMAP_SLOTS > PTRS_PER_PTE
by kernel test robot
Hi Thomas,
FYI, the error/warning still remains.
tree: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
head: 1d1df41c5a33359a00e919d54eaebfb789711fdc
commit: 39cac191ff37939544af80d5d2af6b870fd94c9b arc/mm/highmem: Use generic kmap atomic implementation
date: 1 year, 2 months ago
config: arc-randconfig-r033-20220118 (https://download.01.org/0day-ci/archive/20220120/202201200455.gDoPashc-lk...)
compiler: arceb-elf-gcc (GCC) 11.2.0
reproduce (this is a W=1 build):
wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
chmod +x ~/bin/make.cross
# https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit...
git remote add linus https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
git fetch --no-tags linus master
git checkout 39cac191ff37939544af80d5d2af6b870fd94c9b
# save the config file to linux build tree
mkdir build_dir
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-11.2.0 make.cross O=build_dir ARCH=arc SHELL=/bin/bash arch/arc/mm/
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp(a)intel.com>
All errors (new ones prefixed by >>):
In file included from <command-line>:
arch/arc/mm/highmem.c: In function 'kmap_init':
>> include/linux/compiler_types.h:319:45: error: call to '__compiletime_assert_242' declared with attribute error: BUILD_BUG_ON failed: FIX_KMAP_SLOTS > PTRS_PER_PTE
319 | _compiletime_assert(condition, msg, __compiletime_assert_, __COUNTER__)
| ^
include/linux/compiler_types.h:300:25: note: in definition of macro '__compiletime_assert'
300 | prefix ## suffix(); \
| ^~~~~~
include/linux/compiler_types.h:319:9: note: in expansion of macro '_compiletime_assert'
319 | _compiletime_assert(condition, msg, __compiletime_assert_, __COUNTER__)
| ^~~~~~~~~~~~~~~~~~~
include/linux/build_bug.h:39:37: note: in expansion of macro 'compiletime_assert'
39 | #define BUILD_BUG_ON_MSG(cond, msg) compiletime_assert(!(cond), msg)
| ^~~~~~~~~~~~~~~~~~
include/linux/build_bug.h:50:9: note: in expansion of macro 'BUILD_BUG_ON_MSG'
50 | BUILD_BUG_ON_MSG(condition, "BUILD_BUG_ON failed: " #condition)
| ^~~~~~~~~~~~~~~~
arch/arc/mm/highmem.c:69:9: note: in expansion of macro 'BUILD_BUG_ON'
69 | BUILD_BUG_ON(FIX_KMAP_SLOTS > PTRS_PER_PTE);
| ^~~~~~~~~~~~
vim +/__compiletime_assert_242 +319 include/linux/compiler_types.h
eb5c2d4b45e3d2 Will Deacon 2020-07-21 305
eb5c2d4b45e3d2 Will Deacon 2020-07-21 306 #define _compiletime_assert(condition, msg, prefix, suffix) \
eb5c2d4b45e3d2 Will Deacon 2020-07-21 307 __compiletime_assert(condition, msg, prefix, suffix)
eb5c2d4b45e3d2 Will Deacon 2020-07-21 308
eb5c2d4b45e3d2 Will Deacon 2020-07-21 309 /**
eb5c2d4b45e3d2 Will Deacon 2020-07-21 310 * compiletime_assert - break build and emit msg if condition is false
eb5c2d4b45e3d2 Will Deacon 2020-07-21 311 * @condition: a compile-time constant condition to check
eb5c2d4b45e3d2 Will Deacon 2020-07-21 312 * @msg: a message to emit if condition is false
eb5c2d4b45e3d2 Will Deacon 2020-07-21 313 *
eb5c2d4b45e3d2 Will Deacon 2020-07-21 314 * In tradition of POSIX assert, this macro will break the build if the
eb5c2d4b45e3d2 Will Deacon 2020-07-21 315 * supplied condition is *false*, emitting the supplied error message if the
eb5c2d4b45e3d2 Will Deacon 2020-07-21 316 * compiler has support to do so.
eb5c2d4b45e3d2 Will Deacon 2020-07-21 317 */
eb5c2d4b45e3d2 Will Deacon 2020-07-21 318 #define compiletime_assert(condition, msg) \
eb5c2d4b45e3d2 Will Deacon 2020-07-21 @319 _compiletime_assert(condition, msg, __compiletime_assert_, __COUNTER__)
eb5c2d4b45e3d2 Will Deacon 2020-07-21 320
:::::: The code at line 319 was first introduced by commit
:::::: eb5c2d4b45e3d2d5d052ea6b8f1463976b1020d5 compiler.h: Move compiletime_assert() macros into compiler_types.h
:::::: TO: Will Deacon <will(a)kernel.org>
:::::: CC: Will Deacon <will(a)kernel.org>
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
8 months
sound/soc/codecs/tas5754m.c:246:7: warning: variable 'ret' is used uninitialized whenever switch case is taken
by kernel test robot
tree: https://github.com/0day-ci/linux/commits/UPDATE-20220119-210919/Joerg-Sch...
head: 05b8bf5544bc621031f5a0a6bdf1ac6468a7367b
commit: 05b8bf5544bc621031f5a0a6bdf1ac6468a7367b ASoC: adds component driver for TAS575xM digital amplifiers
date: 5 hours ago
config: riscv-randconfig-c006-20220118 (https://download.01.org/0day-ci/archive/20220120/202201200259.nNgbKOJd-lk...)
compiler: clang version 14.0.0 (https://github.com/llvm/llvm-project f7b7138a62648f4019c55e4671682af1f851f295)
reproduce (this is a W=1 build):
wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
chmod +x ~/bin/make.cross
# install riscv cross compiling tool for clang build
# apt-get install binutils-riscv64-linux-gnu
# https://github.com/0day-ci/linux/commit/05b8bf5544bc621031f5a0a6bdf1ac646...
git remote add linux-review https://github.com/0day-ci/linux
git fetch --no-tags linux-review UPDATE-20220119-210919/Joerg-Schambacher/ASoC-adds-component-driver-for-TAS575xM-digital-amplifiers/20220110-164852
git checkout 05b8bf5544bc621031f5a0a6bdf1ac6468a7367b
# save the config file to linux build tree
mkdir build_dir
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross W=1 O=build_dir ARCH=riscv SHELL=/bin/bash sound/soc/codecs/
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp(a)intel.com>
All warnings (new ones prefixed by >>):
>> sound/soc/codecs/tas5754m.c:246:7: warning: variable 'ret' is used uninitialized whenever switch case is taken [-Wsometimes-uninitialized]
case SND_SOC_BIAS_ON:
^~~~~~~~~~~~~~~
sound/soc/codecs/tas5754m.c:267:9: note: uninitialized use occurs here
return ret;
^~~
sound/soc/codecs/tas5754m.c:247:7: warning: variable 'ret' is used uninitialized whenever switch case is taken [-Wsometimes-uninitialized]
case SND_SOC_BIAS_PREPARE:
^~~~~~~~~~~~~~~~~~~~
sound/soc/codecs/tas5754m.c:267:9: note: uninitialized use occurs here
return ret;
^~~
sound/soc/codecs/tas5754m.c:242:9: note: initialize the variable 'ret' to silence this warning
int ret;
^
= 0
2 warnings generated.
vim +/ret +246 sound/soc/codecs/tas5754m.c
236
237 static int tas5754m_set_bias_level(struct snd_soc_component *component,
238 enum snd_soc_bias_level level)
239 {
240 struct tas5754m_priv *tas5754m =
241 snd_soc_component_get_drvdata(component);
242 int ret;
243
244 switch (level) {
245 default:
> 246 case SND_SOC_BIAS_ON:
247 case SND_SOC_BIAS_PREPARE:
248 break;
249
250 case SND_SOC_BIAS_STANDBY:
251 ret = regmap_update_bits(tas5754m->regmap,
252 TAS5754M_POWER, TAS5754M_RQST, 0);
253 if (ret)
254 dev_err(component->dev,
255 "Failed to remove standby: %d\n", ret);
256 break;
257
258 case SND_SOC_BIAS_OFF:
259 ret = regmap_update_bits(tas5754m->regmap,
260 TAS5754M_POWER, TAS5754M_RQST, TAS5754M_RQST);
261 if (ret)
262 dev_err(component->dev,
263 "Failed to request standby: %d\n", ret);
264 break;
265 }
266
267 return ret;
268 }
269
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
8 months
Re: [PATCH v1] usb: hub: Power cycle root hub if CSC is set during hub_port_reset
by kernel test robot
Hi Pratham,
Thank you for the patch! Yet something to improve:
[auto build test ERROR on usb/usb-testing]
[also build test ERROR on linus/master peter-chen-usb/for-usb-next v5.16 next-20220118]
[cannot apply to balbi-usb/testing/next]
[If your patch is applied to the wrong git tree, kindly drop us a note.
And when submitting patch, we suggest to use '--base' as documented in
https://git-scm.com/docs/git-format-patch]
url: https://github.com/0day-ci/linux/commits/Pratham-Pratap/usb-hub-Power-cyc...
base: https://git.kernel.org/pub/scm/linux/kernel/git/gregkh/usb.git usb-testing
config: alpha-allmodconfig (https://download.01.org/0day-ci/archive/20220120/202201200108.JJYDWfTS-lk...)
compiler: alpha-linux-gcc (GCC) 11.2.0
reproduce (this is a W=1 build):
wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
chmod +x ~/bin/make.cross
# https://github.com/0day-ci/linux/commit/ec4d5f04b268fc19d3b5d2843d1889531...
git remote add linux-review https://github.com/0day-ci/linux
git fetch --no-tags linux-review Pratham-Pratap/usb-hub-Power-cycle-root-hub-if-CSC-is-set-during-hub_port_reset/20220119-235321
git checkout ec4d5f04b268fc19d3b5d2843d1889531dafd22f
# save the config file to linux build tree
mkdir build_dir
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-11.2.0 make.cross O=build_dir ARCH=alpha SHELL=/bin/bash drivers/usb/
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp(a)intel.com>
All errors (new ones prefixed by >>):
drivers/usb/core/hub.c: In function 'hub_port_wait_reset':
>> drivers/usb/core/hub.c:2907:25: error: 'struct usb_device' has no member named 'reset_resume'
2907 | if (udev->reset_resume && (!udev->parent && hcd->fs_suspend_reset) &&
| ^~
>> drivers/usb/core/hub.c:2909:50: error: 'hdev' undeclared (first use in this function); did you mean 'udev'?
2909 | usb_hub_port_power_cycle(hdev, hub, port1);
| ^~~~
| udev
drivers/usb/core/hub.c:2909:50: note: each undeclared identifier is reported only once for each function it appears in
vim +2907 drivers/usb/core/hub.c
2845
2846 static int hub_port_wait_reset(struct usb_hub *hub, int port1,
2847 struct usb_device *udev, unsigned int delay, bool warm)
2848 {
2849 int delay_time, ret;
2850 struct usb_hcd *hcd = bus_to_hcd(udev->bus);
2851 u16 portstatus;
2852 u16 portchange;
2853 u32 ext_portstatus = 0;
2854
2855 for (delay_time = 0;
2856 delay_time < HUB_RESET_TIMEOUT;
2857 delay_time += delay) {
2858 /* wait to give the device a chance to reset */
2859 msleep(delay);
2860
2861 /* read and decode port status */
2862 if (hub_is_superspeedplus(hub->hdev))
2863 ret = hub_ext_port_status(hub, port1,
2864 HUB_EXT_PORT_STATUS,
2865 &portstatus, &portchange,
2866 &ext_portstatus);
2867 else
2868 ret = hub_port_status(hub, port1, &portstatus,
2869 &portchange);
2870 if (ret < 0)
2871 return ret;
2872
2873 /*
2874 * The port state is unknown until the reset completes.
2875 *
2876 * On top of that, some chips may require additional time
2877 * to re-establish a connection after the reset is complete,
2878 * so also wait for the connection to be re-established.
2879 */
2880 if (!(portstatus & USB_PORT_STAT_RESET) &&
2881 (portstatus & USB_PORT_STAT_CONNECTION))
2882 break;
2883
2884 /* switch to the long delay after two short delay failures */
2885 if (delay_time >= 2 * HUB_SHORT_RESET_TIME)
2886 delay = HUB_LONG_RESET_TIME;
2887
2888 dev_dbg(&hub->ports[port1 - 1]->dev,
2889 "not %sreset yet, waiting %dms\n",
2890 warm ? "warm " : "", delay);
2891 }
2892
2893 if ((portstatus & USB_PORT_STAT_RESET))
2894 return -EBUSY;
2895
2896 if (hub_port_warm_reset_required(hub, port1, portstatus))
2897 return -ENOTCONN;
2898
2899 /* Device went away? */
2900 if (!(portstatus & USB_PORT_STAT_CONNECTION)) {
2901 /*
2902 * When a FS device is following a suspend-reset-enumeration-data_transfer
2903 * sequence, sometimes it goes back in suspend just after reset without the
2904 * link entering L0. To fix this when CSC bit is set(because of CCS status
2905 * change) power cycle the root hub.
2906 */
> 2907 if (udev->reset_resume && (!udev->parent && hcd->fs_suspend_reset) &&
2908 (portstatus & USB_PORT_STAT_CSC)) {
> 2909 usb_hub_port_power_cycle(hdev, hub, port1);
2910 return -EAGAIN;
2911 }
2912
2913 return -ENOTCONN;
2914 }
2915
2916 /* Retry if connect change is set but status is still connected.
2917 * A USB 3.0 connection may bounce if multiple warm resets were issued,
2918 * but the device may have successfully re-connected. Ignore it.
2919 */
2920 if (!hub_is_superspeed(hub->hdev) &&
2921 (portchange & USB_PORT_STAT_C_CONNECTION)) {
2922 usb_clear_port_feature(hub->hdev, port1,
2923 USB_PORT_FEAT_C_CONNECTION);
2924 return -EAGAIN;
2925 }
2926
2927 if (!(portstatus & USB_PORT_STAT_ENABLE))
2928 return -EBUSY;
2929
2930 if (!udev)
2931 return 0;
2932
2933 if (hub_is_superspeedplus(hub->hdev)) {
2934 /* extended portstatus Rx and Tx lane count are zero based */
2935 udev->rx_lanes = USB_EXT_PORT_RX_LANES(ext_portstatus) + 1;
2936 udev->tx_lanes = USB_EXT_PORT_TX_LANES(ext_portstatus) + 1;
2937 udev->ssp_rate = get_port_ssp_rate(hub->hdev, ext_portstatus);
2938 } else {
2939 udev->rx_lanes = 1;
2940 udev->tx_lanes = 1;
2941 udev->ssp_rate = USB_SSP_GEN_UNKNOWN;
2942 }
2943 if (hub_is_wusb(hub))
2944 udev->speed = USB_SPEED_WIRELESS;
2945 else if (udev->ssp_rate != USB_SSP_GEN_UNKNOWN)
2946 udev->speed = USB_SPEED_SUPER_PLUS;
2947 else if (hub_is_superspeed(hub->hdev))
2948 udev->speed = USB_SPEED_SUPER;
2949 else if (portstatus & USB_PORT_STAT_HIGH_SPEED)
2950 udev->speed = USB_SPEED_HIGH;
2951 else if (portstatus & USB_PORT_STAT_LOW_SPEED)
2952 udev->speed = USB_SPEED_LOW;
2953 else
2954 udev->speed = USB_SPEED_FULL;
2955 return 0;
2956 }
2957
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
8 months
net/bpf/bpf_dummy_struct_ops.c:122:6: error: unexpected token, expected comma
by kernel test robot
tree: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
head: 1d1df41c5a33359a00e919d54eaebfb789711fdc
commit: c196906d50e360d82ed9aa5596a9d0ce89b7ab78 bpf: Add dummy BPF STRUCT_OPS for test purpose
date: 3 months ago
config: mips-randconfig-r003-20220118 (https://download.01.org/0day-ci/archive/20220120/202201200024.lLbhNvJC-lk...)
compiler: clang version 14.0.0 (https://github.com/llvm/llvm-project 5f782d25a742302d25ef3c8b84b54f7483c2deb9)
reproduce (this is a W=1 build):
wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
chmod +x ~/bin/make.cross
# install mips cross compiling tool for clang build
# apt-get install binutils-mips-linux-gnu
# https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit...
git remote add linus https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
git fetch --no-tags linus master
git checkout c196906d50e360d82ed9aa5596a9d0ce89b7ab78
# save the config file to linux build tree
mkdir build_dir
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross W=1 O=build_dir ARCH=mips SHELL=/bin/bash drivers/cxl/ mm// net/
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp(a)intel.com>
All errors (new ones prefixed by >>):
>> net/bpf/bpf_dummy_struct_ops.c:122:6: error: unexpected token, expected comma
if (put_user(prog_ret, &uattr->test.retval))
^
arch/mips/include/asm/uaccess.h:112:33: note: expanded from macro 'put_user'
access_ok(__p, sizeof(*__p)) ? __put_user((x), __p) : -EFAULT; \
^
arch/mips/include/asm/uaccess.h:177:18: note: expanded from macro '__put_user'
__put_data_asm(user_sw, __pu_ptr); \
^
<inline asm>:3:10: note: instantiated into assembly here
.set eva
^
>> net/bpf/bpf_dummy_struct_ops.c:122:6: error: invalid operand for instruction
if (put_user(prog_ret, &uattr->test.retval))
^
arch/mips/include/asm/uaccess.h:112:33: note: expanded from macro 'put_user'
access_ok(__p, sizeof(*__p)) ? __put_user((x), __p) : -EFAULT; \
^
arch/mips/include/asm/uaccess.h:177:18: note: expanded from macro '__put_user'
__put_data_asm(user_sw, __pu_ptr); \
^
<inline asm>:4:11: note: instantiated into assembly here
swe $19, 0($2)
^
2 errors generated.
vim +122 net/bpf/bpf_dummy_struct_ops.c
74
75 int bpf_struct_ops_test_run(struct bpf_prog *prog, const union bpf_attr *kattr,
76 union bpf_attr __user *uattr)
77 {
78 const struct bpf_struct_ops *st_ops = &bpf_bpf_dummy_ops;
79 const struct btf_type *func_proto;
80 struct bpf_dummy_ops_test_args *args;
81 struct bpf_tramp_progs *tprogs;
82 void *image = NULL;
83 unsigned int op_idx;
84 int prog_ret;
85 int err;
86
87 if (prog->aux->attach_btf_id != st_ops->type_id)
88 return -EOPNOTSUPP;
89
90 func_proto = prog->aux->attach_func_proto;
91 args = dummy_ops_init_args(kattr, btf_type_vlen(func_proto));
92 if (IS_ERR(args))
93 return PTR_ERR(args);
94
95 tprogs = kcalloc(BPF_TRAMP_MAX, sizeof(*tprogs), GFP_KERNEL);
96 if (!tprogs) {
97 err = -ENOMEM;
98 goto out;
99 }
100
101 image = bpf_jit_alloc_exec(PAGE_SIZE);
102 if (!image) {
103 err = -ENOMEM;
104 goto out;
105 }
106 set_vm_flush_reset_perms(image);
107
108 op_idx = prog->expected_attach_type;
109 err = bpf_struct_ops_prepare_trampoline(tprogs, prog,
110 &st_ops->func_models[op_idx],
111 image, image + PAGE_SIZE);
112 if (err < 0)
113 goto out;
114
115 set_memory_ro((long)image, 1);
116 set_memory_x((long)image, 1);
117 prog_ret = dummy_ops_call_op(image, args);
118
119 err = dummy_ops_copy_args(args);
120 if (err)
121 goto out;
> 122 if (put_user(prog_ret, &uattr->test.retval))
123 err = -EFAULT;
124 out:
125 kfree(args);
126 bpf_jit_free_exec(image);
127 kfree(tprogs);
128 return err;
129 }
130
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
8 months
[xilinx-xlnx:master 340/360] drivers/phy/xilinx/xilinx_dpgtquadphy.c:49:17: error: implicit declaration of function 'FIELD_PREP'
by kernel test robot
tree: https://github.com/Xilinx/linux-xlnx master
head: dc405906cdb8a89cd81b6ca4f438fe213c187cb2
commit: a2af060c77e92bff35d0f7176cc5139115ff29b9 [340/360] phy: Add driver for GTQUAD BASE for Displayport
config: parisc-allyesconfig (https://download.01.org/0day-ci/archive/20220119/202201192322.1y7ZM7N6-lk...)
compiler: hppa-linux-gcc (GCC) 11.2.0
reproduce (this is a W=1 build):
wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
chmod +x ~/bin/make.cross
# https://github.com/Xilinx/linux-xlnx/commit/a2af060c77e92bff35d0f7176cc51...
git remote add xilinx-xlnx https://github.com/Xilinx/linux-xlnx
git fetch --no-tags xilinx-xlnx master
git checkout a2af060c77e92bff35d0f7176cc5139115ff29b9
# save the config file to linux build tree
mkdir build_dir
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-11.2.0 make.cross O=build_dir ARCH=parisc SHELL=/bin/bash
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp(a)intel.com>
All errors (new ones prefixed by >>):
drivers/phy/xilinx/xilinx_dpgtquadphy.c: In function 'xdpgtquad_init':
>> drivers/phy/xilinx/xilinx_dpgtquadphy.c:49:17: error: implicit declaration of function 'FIELD_PREP' [-Werror=implicit-function-declaration]
49 | data |= FIELD_PREP(GT_QUAD_BASE_CH1_CLK_DIV_MASK,
| ^~~~~~~~~~
cc1: some warnings being treated as errors
Kconfig warnings: (for reference only)
WARNING: unmet direct dependencies detected for DRM_PANEL_SIMPLE
Depends on HAS_IOMEM && DRM && DRM_PANEL && OF && BACKLIGHT_CLASS_DEVICE && PM
Selected by
- DRM_XLNX_DSI && HAS_IOMEM && DRM_XLNX
vim +/FIELD_PREP +49 drivers/phy/xilinx/xilinx_dpgtquadphy.c
34
35 static int xdpgtquad_init(struct phy *phy)
36 {
37 struct dpgtquadphy_dev *gtquad = phy_get_drvdata(phy);
38 u32 data;
39
40 /*
41 * Unlocking the NPI space so that GT CH1 divider value can be
42 * programmed. This will generate a /20 clk
43 */
44 writel(GT_QUAD_BASE_CTL_VALUE,
45 gtquad->base + GT_QUAD_BASE_CTL);
46
47 data = readl(gtquad->base + GT_QUAD_BASE_CH1_CLK_DIV_REG);
48 data &= ~GT_QUAD_BASE_CH1_CLK_DIV_MASK;
> 49 data |= FIELD_PREP(GT_QUAD_BASE_CH1_CLK_DIV_MASK,
50 GT_QUAD_BASE_CH1_CLK_DIV_VALUE);
51 writel(data, gtquad->base + GT_QUAD_BASE_CH1_CLK_DIV_REG);
52
53 return 0;
54 }
55
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
8 months