* [PATCH linux dev-4.7 v2] drivers/fsi: Change hub sysfs name
@ 2017-03-02 21:46 Christopher Bostic
2017-03-03 7:51 ` Joel Stanley
0 siblings, 1 reply; 2+ messages in thread
From: Christopher Bostic @ 2017-03-02 21:46 UTC (permalink / raw
To: joel; +Cc: Christopher Bostic, openbmc
Fix duplicate "hub@00" naming bug when two or more hubs are
detected during scan. Each hub was assigned id '00'. Duplicate
hub device names were causing kernel warnings to console on
every scan. Create a unique name by using the upstream master's
idx field. i.e. hub@00, hub@01, ...
Signed-off-by: Christopher Bostic <cbostic@linux.vnet.ibm.com>
---
v2:
Add more description for the change.
---
drivers/fsi/fsi-core.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/fsi/fsi-core.c b/drivers/fsi/fsi-core.c
index 542544e..b9573c5 100644
--- a/drivers/fsi/fsi-core.c
+++ b/drivers/fsi/fsi-core.c
@@ -437,7 +437,7 @@ static int fsi_slave_scan(struct fsi_slave *slave)
return -ENOMEM;
device_initialize(&hub->dev);
- dev_set_name(&hub->dev, "hub@%02x", hub->master.idx);
+ dev_set_name(&hub->dev, "hub@%02x", slave->master->idx);
hub->dev.release = hub_master_release;
rc = device_add(&hub->dev);
if (rc)
--
1.8.2.2
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [PATCH linux dev-4.7 v2] drivers/fsi: Change hub sysfs name
2017-03-02 21:46 [PATCH linux dev-4.7 v2] drivers/fsi: Change hub sysfs name Christopher Bostic
@ 2017-03-03 7:51 ` Joel Stanley
0 siblings, 0 replies; 2+ messages in thread
From: Joel Stanley @ 2017-03-03 7:51 UTC (permalink / raw
To: Christopher Bostic; +Cc: OpenBMC Maillist
On Fri, Mar 3, 2017 at 8:16 AM, Christopher Bostic
<cbostic@linux.vnet.ibm.com> wrote:
> Fix duplicate "hub@00" naming bug when two or more hubs are
> detected during scan. Each hub was assigned id '00'. Duplicate
> hub device names were causing kernel warnings to console on
> every scan. Create a unique name by using the upstream master's
> idx field. i.e. hub@00, hub@01, ...
>
> Signed-off-by: Christopher Bostic <cbostic@linux.vnet.ibm.com>
> ---
> v2:
> Add more description for the change.
Much better commit message. Thanks for the explanation.
Applied to dev-4.7.
Cheers,
Joel
> ---
> drivers/fsi/fsi-core.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/fsi/fsi-core.c b/drivers/fsi/fsi-core.c
> index 542544e..b9573c5 100644
> --- a/drivers/fsi/fsi-core.c
> +++ b/drivers/fsi/fsi-core.c
> @@ -437,7 +437,7 @@ static int fsi_slave_scan(struct fsi_slave *slave)
> return -ENOMEM;
>
> device_initialize(&hub->dev);
> - dev_set_name(&hub->dev, "hub@%02x", hub->master.idx);
> + dev_set_name(&hub->dev, "hub@%02x", slave->master->idx);
> hub->dev.release = hub_master_release;
> rc = device_add(&hub->dev);
> if (rc)
> --
> 1.8.2.2
>
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2017-03-03 7:51 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2017-03-02 21:46 [PATCH linux dev-4.7 v2] drivers/fsi: Change hub sysfs name Christopher Bostic
2017-03-03 7:51 ` Joel Stanley
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.