From: Michal Simek <michal.simek@amd.com>
To: Greg KH <gregkh@linuxfoundation.org>,
Radhey Shyam Pandey <radhey.shyam.pandey@amd.com>
Cc: mka@chromium.org, paul.walmsley@sifive.com, palmer@dabbelt.com,
aou@eecs.berkeley.edu, wentong.wu@intel.com, oneukum@suse.com,
javier.carrasco@wolfvision.net, matthias@kaehlcke.net,
linux-usb@vger.kernel.org, linux-kernel@vger.kernel.org,
linux-riscv@lists.infradead.org, git@amd.com
Subject: Re: [PATCH] usb: misc: onboard_usb_dev: introduce new config symbol for usb5744 SMBus support
Date: Wed, 25 Sep 2024 08:59:00 +0200 [thread overview]
Message-ID: <4da1353f-1209-43ba-930e-7b4f4a0cb2eb@amd.com> (raw)
In-Reply-To: <2024092551-fiddle-flatterer-e643@gregkh>
On 9/25/24 08:33, Greg KH wrote:
> On Tue, Sep 24, 2024 at 07:49:11PM +0530, Radhey Shyam Pandey wrote:
>> Introduce new kernel config symbol for Microchip usb5744 SMBus programming
>> support. Since usb5744 i2c initialization routine uses i2c SMBus APIs these
>> APIs should only be invoked when kernel has I2C support. This new kernel
>> config describes the dependency on I2C kernel support and fix the below
>> build issues when USB_ONBOARD_DEV=y and CONFIG_I2C=m.
>>
>> riscv64-linux-ld: drivers/usb/misc/onboard_usb_dev.o:
>> undefined reference to `i2c_find_device_by_fwnode'
>> drivers/usb/misc/onboard_usb_dev.c:408:(.text+0xb24): undefined
>> reference to `i2c_smbus_write_block_data'
>> <snip>
>>
>> Parsing of the i2c-bus bus handle is not put under usb5744 kernel config
>> check as the intention is to report an error when DT is configured for
>> usb5744 SMBus support and kernel has USB_ONBOARD_DEV_USB5744 disabled.
>>
>> Fixes: 6782311d04df ("usb: misc: onboard_usb_dev: add Microchip usb5744 SMBus programming support")
>> Signed-off-by: Radhey Shyam Pandey <radhey.shyam.pandey@amd.com>
>> Suggested-by: Matthias Kaehlcke <matthias@kaehlcke.net>
>> Reported-by: kernel test robot <lkp@intel.com>
>> Closes: https://lore.kernel.org/oe-kbuild-all/202409140539.3Axwv38m-lkp@intel.com/
>> ---
>> drivers/usb/misc/Kconfig | 11 +++++++++++
>> drivers/usb/misc/onboard_usb_dev.c | 6 ++++--
>> 2 files changed, 15 insertions(+), 2 deletions(-)
>>
>> diff --git a/drivers/usb/misc/Kconfig b/drivers/usb/misc/Kconfig
>> index 50b86d531701..29976a93f122 100644
>> --- a/drivers/usb/misc/Kconfig
>> +++ b/drivers/usb/misc/Kconfig
>> @@ -331,3 +331,14 @@ config USB_ONBOARD_DEV
>> this config will enable the driver and it will automatically
>> match the state of the USB subsystem. If this driver is a
>> module it will be called onboard_usb_dev.
>> +
>> +config USB_ONBOARD_DEV_USB5744
>> + bool "Onboard USB Microchip usb5744 hub with SMBus support"
>> + depends on (USB_ONBOARD_DEV && I2C=y) || (USB_ONBOARD_DEV=m && I2C=m)
>> + default y
>
> "default y" is if you can not boot without this option enabled for all
> Linux systems. I doubt that is the case here :(
Intention is to have it enabled when USB_ONBOARD_DEV is enabled with all other
conditions. In our case where our HW guys started to use this usb hub with
usb-sd convertor where rootfs is on it. Without usb hub initialization via i2c
we are not able to boot our system.
Thanks,
Michal
next prev parent reply other threads:[~2024-09-25 6:59 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-09-24 14:19 [PATCH] usb: misc: onboard_usb_dev: introduce new config symbol for usb5744 SMBus support Radhey Shyam Pandey
2024-09-24 16:26 ` Matthias Kaehlcke
2024-09-25 6:33 ` Greg KH
2024-09-25 6:59 ` Michal Simek [this message]
2024-09-25 8:07 ` Greg KH
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=4da1353f-1209-43ba-930e-7b4f4a0cb2eb@amd.com \
--to=michal.simek@amd.com \
--cc=aou@eecs.berkeley.edu \
--cc=git@amd.com \
--cc=gregkh@linuxfoundation.org \
--cc=javier.carrasco@wolfvision.net \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-riscv@lists.infradead.org \
--cc=linux-usb@vger.kernel.org \
--cc=matthias@kaehlcke.net \
--cc=mka@chromium.org \
--cc=oneukum@suse.com \
--cc=palmer@dabbelt.com \
--cc=paul.walmsley@sifive.com \
--cc=radhey.shyam.pandey@amd.com \
--cc=wentong.wu@intel.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox