* [PATCH] usb: linux/usb.h: Correct the description of the usb_device_driver member
@ 2025-12-01 8:53 Yi Cong
2025-12-01 15:14 ` Alan Stern
0 siblings, 1 reply; 4+ messages in thread
From: Yi Cong @ 2025-12-01 8:53 UTC (permalink / raw)
To: gregkh; +Cc: linux-usb, linux-kernel, yicong
From: Yi Cong <yicong@kylinos.cn>
In the current kernel USB device driver code, only the name field is
required to be provided; all other fields are optional.
Use the command grep -rnw "struct usb_device_driver" to inspect
how specific drivers are declared.
Correct this part of the description.
Signed-off-by: Yi Cong <yicong@kylinos.cn>
---
include/linux/usb.h | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)
diff --git a/include/linux/usb.h b/include/linux/usb.h
index e85105939af8e..fbfcc70b07fbe 100644
--- a/include/linux/usb.h
+++ b/include/linux/usb.h
@@ -1295,8 +1295,7 @@ struct usb_driver {
* resume and suspend functions will be called in addition to the driver's
* own, so this part of the setup does not need to be replicated.
*
- * USB drivers must provide all the fields listed above except driver,
- * match, and id_table.
+ * USB device drivers must provide a name, other driver fields are optional.
*/
struct usb_device_driver {
const char *name;
--
2.25.1
^ permalink raw reply related [flat|nested] 4+ messages in thread
* Re: [PATCH] usb: linux/usb.h: Correct the description of the usb_device_driver member
2025-12-01 8:53 [PATCH] usb: linux/usb.h: Correct the description of the usb_device_driver member Yi Cong
@ 2025-12-01 15:14 ` Alan Stern
2025-12-02 6:59 ` Yi Cong
0 siblings, 1 reply; 4+ messages in thread
From: Alan Stern @ 2025-12-01 15:14 UTC (permalink / raw)
To: Yi Cong; +Cc: gregkh, linux-usb, linux-kernel, yicong
On Mon, Dec 01, 2025 at 04:53:09PM +0800, Yi Cong wrote:
> From: Yi Cong <yicong@kylinos.cn>
>
> In the current kernel USB device driver code, only the name field is
> required to be provided; all other fields are optional.
> Use the command grep -rnw "struct usb_device_driver" to inspect
> how specific drivers are declared.
That last sentence should not be part of the patch description; it
doesn't explain the patch's purpose or what the patch does. (It's not
even correct, because the grep output doesn't show how the specific
drivers are declared. It mainly shows the filenames and line numbers
where the declarations start.)
Aside from that,
Acked-by: Alan Stern <stern@rowland.harvard.edu>
Alan Stern
> Correct this part of the description.
>
> Signed-off-by: Yi Cong <yicong@kylinos.cn>
> ---
> include/linux/usb.h | 3 +--
> 1 file changed, 1 insertion(+), 2 deletions(-)
>
> diff --git a/include/linux/usb.h b/include/linux/usb.h
> index e85105939af8e..fbfcc70b07fbe 100644
> --- a/include/linux/usb.h
> +++ b/include/linux/usb.h
> @@ -1295,8 +1295,7 @@ struct usb_driver {
> * resume and suspend functions will be called in addition to the driver's
> * own, so this part of the setup does not need to be replicated.
> *
> - * USB drivers must provide all the fields listed above except driver,
> - * match, and id_table.
> + * USB device drivers must provide a name, other driver fields are optional.
> */
> struct usb_device_driver {
> const char *name;
> --
> 2.25.1
>
>
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH] usb: linux/usb.h: Correct the description of the usb_device_driver member
2025-12-01 15:14 ` Alan Stern
@ 2025-12-02 6:59 ` Yi Cong
2025-12-02 9:00 ` Greg KH
0 siblings, 1 reply; 4+ messages in thread
From: Yi Cong @ 2025-12-02 6:59 UTC (permalink / raw)
To: stern; +Cc: gregkh, linux-kernel, linux-usb, yicong
On Mon, 1 Dec 2025 10:14:04 -0500, Alan Stern <stern@rowland.harvard.edu> wrote:
>
> On Mon, Dec 01, 2025 at 04:53:09PM +0800, Yi Cong wrote:
> > From: Yi Cong <yicong@kylinos.cn>
> >
> > In the current kernel USB device driver code, only the name field is
> > required to be provided; all other fields are optional.
> > Use the command grep -rnw "struct usb_device_driver" to inspect
> > how specific drivers are declared.
>
> That last sentence should not be part of the patch description; it
> doesn't explain the patch's purpose or what the patch does. (It's not
> even correct, because the grep output doesn't show how the specific
> drivers are declared. It mainly shows the filenames and line numbers
> where the declarations start.)
>
Thank you for the reply!
Do I need to update the commit message and send a new version of the patch?
Regards,
Yi Cong
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH] usb: linux/usb.h: Correct the description of the usb_device_driver member
2025-12-02 6:59 ` Yi Cong
@ 2025-12-02 9:00 ` Greg KH
0 siblings, 0 replies; 4+ messages in thread
From: Greg KH @ 2025-12-02 9:00 UTC (permalink / raw)
To: Yi Cong; +Cc: stern, linux-kernel, linux-usb, yicong
On Tue, Dec 02, 2025 at 02:59:17PM +0800, Yi Cong wrote:
> On Mon, 1 Dec 2025 10:14:04 -0500, Alan Stern <stern@rowland.harvard.edu> wrote:
> >
> > On Mon, Dec 01, 2025 at 04:53:09PM +0800, Yi Cong wrote:
> > > From: Yi Cong <yicong@kylinos.cn>
> > >
> > > In the current kernel USB device driver code, only the name field is
> > > required to be provided; all other fields are optional.
> > > Use the command grep -rnw "struct usb_device_driver" to inspect
> > > how specific drivers are declared.
> >
> > That last sentence should not be part of the patch description; it
> > doesn't explain the patch's purpose or what the patch does. (It's not
> > even correct, because the grep output doesn't show how the specific
> > drivers are declared. It mainly shows the filenames and line numbers
> > where the declarations start.)
> >
>
> Thank you for the reply!
> Do I need to update the commit message and send a new version of the patch?
Yes please.
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2025-12-02 9:00 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-12-01 8:53 [PATCH] usb: linux/usb.h: Correct the description of the usb_device_driver member Yi Cong
2025-12-01 15:14 ` Alan Stern
2025-12-02 6:59 ` Yi Cong
2025-12-02 9:00 ` Greg KH
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).