tree:
https://git.kernel.org/pub/scm/linux/kernel/git/sashal/linux-stable.git
queue-5.12
head: 3532c052dc69afdb1ee28acd8c82a2a7e38e8878
commit: 0b7b4793dcc0711016a7550124626992de48d274 [82/97] usb: dwc2: Update enter and exit
partial power down functions
config: i386-randconfig-s001-20210607 (attached as .config)
compiler: gcc-9 (Debian 9.3.0-22) 9.3.0
reproduce:
# apt-get install sparse
# sparse version: v0.6.3-341-g8af24329-dirty
#
https://git.kernel.org/pub/scm/linux/kernel/git/sashal/linux-stable.git/c...
git remote add sashal-linux-stable
https://git.kernel.org/pub/scm/linux/kernel/git/sashal/linux-stable.git
git fetch --no-tags sashal-linux-stable queue-5.12
git checkout 0b7b4793dcc0711016a7550124626992de48d274
# save the attached .config to linux build tree
make W=1 C=1 CF='-fdiagnostic-prefix -D__CHECK_ENDIAN__' W=1 ARCH=i386
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/dwc2/core.c: In function 'dwc2_exit_partial_power_down':
> drivers/usb/dwc2/core.c:150:10: error: implicit declaration of
function 'dwc2_host_exit_partial_power_down'; did you mean
'dwc2_exit_partial_power_down'? [-Werror=implicit-function-declaration]
150 | return dwc2_host_exit_partial_power_down(hsotg, rem_wakeup,
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
| dwc2_exit_partial_power_down
> drivers/usb/dwc2/core.c:153:10: error: implicit declaration of
function 'dwc2_gadget_exit_partial_power_down'; did you mean
'dwc2_exit_partial_power_down'? [-Werror=implicit-function-declaration]
153 | return dwc2_gadget_exit_partial_power_down(hsotg, restore);
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
| dwc2_exit_partial_power_down
drivers/usb/dwc2/core.c: In function 'dwc2_enter_partial_power_down':
> drivers/usb/dwc2/core.c:164:10: error: implicit declaration of
function 'dwc2_host_enter_partial_power_down'; did you mean
'dwc2_enter_partial_power_down'? [-Werror=implicit-function-declaration]
164 | return dwc2_host_enter_partial_power_down(hsotg);
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
| dwc2_enter_partial_power_down
> drivers/usb/dwc2/core.c:166:10: error: implicit declaration of
function 'dwc2_gadget_enter_partial_power_down'; did you mean
'dwc2_enter_partial_power_down'? [-Werror=implicit-function-declaration]
166 | return dwc2_gadget_enter_partial_power_down(hsotg);
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
| dwc2_enter_partial_power_down
cc1: some warnings being treated as errors
--
drivers/usb/dwc2/core_intr.c: In function 'dwc2_handle_session_req_intr':
> drivers/usb/dwc2/core_intr.c:319:42: error: 'struct
dwc2_hsotg' has no member named 'in_ppd'
319 | if
(hsotg->lx_state == DWC2_L2 && hsotg->in_ppd) {
| ^~
drivers/usb/dwc2/core_intr.c: In function 'dwc2_handle_wakeup_detected_intr':
drivers/usb/dwc2/core_intr.c:418:42: error: 'struct dwc2_hsotg' has no member
named 'in_ppd'
418 | if (hsotg->lx_state == DWC2_L2 && hsotg->in_ppd) {
| ^~
drivers/usb/dwc2/core_intr.c: In function 'dwc_handle_gpwrdn_disc_det':
drivers/usb/dwc2/core_intr.c:709:7: error: 'struct dwc2_hsotg' has no member
named 'bus_suspended'
709 | hsotg->bus_suspended = 0;
| ^~
--
drivers/usb/dwc2/gadget.c: In function 'dwc2_hsotg_irq':
> drivers/usb/dwc2/gadget.c:3693:12: error: 'struct
dwc2_hsotg' has no member named 'in_ppd'
3693 | if
(hsotg->in_ppd && hsotg->lx_state == DWC2_L2)
| ^~
drivers/usb/dwc2/gadget.c: In function 'dwc2_hsotg_vbus_session':
drivers/usb/dwc2/gadget.c:4622:41: error: 'struct dwc2_hsotg' has no member
named 'in_ppd'
4622 | if (hsotg->lx_state == DWC2_L2 && hsotg->in_ppd)
| ^~
vim +150 drivers/usb/dwc2/core.c
129
130 /**
131 * dwc2_exit_partial_power_down() - Exit controller from Partial Power Down.
132 *
133 * @hsotg: Programming view of the DWC_otg controller
134 * @rem_wakeup: indicates whether resume is initiated by Reset.
135 * @restore: Controller registers need to be restored
136 */
137 int dwc2_exit_partial_power_down(struct dwc2_hsotg *hsotg, int rem_wakeup,
138 bool restore)
139 {
140 struct dwc2_gregs_backup *gr;
141
142 gr = &hsotg->gr_backup;
143
144 /*
145 * Restore host or device regisers with the same mode core enterted
146 * to partial power down by checking "GOTGCTL_CURMODE_HOST" backup
147 * value of the "gotgctl" register.
148 */
149 if (gr->gotgctl & GOTGCTL_CURMODE_HOST)
150 return dwc2_host_exit_partial_power_down(hsotg, rem_wakeup,
151 restore);
152 else
153 return dwc2_gadget_exit_partial_power_down(hsotg, restore);
154 }
155
156 /**
157 * dwc2_enter_partial_power_down() - Put controller in Partial Power Down.
158 *
159 * @hsotg: Programming view of the DWC_otg controller
160 */
161 int dwc2_enter_partial_power_down(struct dwc2_hsotg *hsotg)
162 {
163 if (dwc2_is_host_mode(hsotg))
164 return dwc2_host_enter_partial_power_down(hsotg);
165 else
166 return dwc2_gadget_enter_partial_power_down(hsotg);
167 }
168
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org