* Re: [PATCH] staging: usbip: replace pr_warning() with pr_warn()
@ 2013-06-25 10:57 navin patidar
2013-06-25 14:54 ` Greg KH
0 siblings, 1 reply; 5+ messages in thread
From: navin patidar @ 2013-06-25 10:57 UTC (permalink / raw)
To: Greg KH; +Cc: mfm, linux-usb, devel, linux-kernel
On Tue, Jun 25, 2013, Greg KH <gregkh@linuxfoundation.org> said:
> On Fri, Jun 21, 2013 at 03:01:04PM +0530, navin patidar wrote:
>> pr_warn() is preferred over pr_warning().
>
> And dev_warn() is preferred over both of them, can you convert the code
> to use that instead?
>
struct device is not available in usbip_start_eh() which is required
for dev_warn().
usbip_device's containers struct stub_device and struct vhci_device
both have member structure usb_device but inside usbip_start_eh(), it
is difficult to determine to which container struct usbip_device
belongs, thus container_of() can not be used here to get struct
usb_device.
regards,
--navin-patidar
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH] staging: usbip: replace pr_warning() with pr_warn()
2013-06-25 10:57 [PATCH] staging: usbip: replace pr_warning() with pr_warn() navin patidar
@ 2013-06-25 14:54 ` Greg KH
0 siblings, 0 replies; 5+ messages in thread
From: Greg KH @ 2013-06-25 14:54 UTC (permalink / raw)
To: navin patidar; +Cc: mfm, linux-usb, devel, linux-kernel
On Tue, Jun 25, 2013 at 04:27:18PM +0530, navin patidar wrote:
> On Tue, Jun 25, 2013, Greg KH <gregkh@linuxfoundation.org> said:
>
> > On Fri, Jun 21, 2013 at 03:01:04PM +0530, navin patidar wrote:
> >> pr_warn() is preferred over pr_warning().
> >
> > And dev_warn() is preferred over both of them, can you convert the code
> > to use that instead?
> >
>
> struct device is not available in usbip_start_eh() which is required
> for dev_warn().
>
> usbip_device's containers struct stub_device and struct vhci_device
> both have member structure usb_device but inside usbip_start_eh(), it
> is difficult to determine to which container struct usbip_device
> belongs, thus container_of() can not be used here to get struct
> usb_device.
Then the code should be reworked in order to be able to properly
determine that.
greg k-h
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH] staging: usbip: replace pr_warning() with pr_warn()
@ 2013-06-26 6:42 navin patidar
0 siblings, 0 replies; 5+ messages in thread
From: navin patidar @ 2013-06-26 6:42 UTC (permalink / raw)
To: Greg KH; +Cc: mfm, linux-usb, devel, linux-kernel
On Tue, Jun 25, 2013, Greg KH <gregkh@linuxfoundation.org> said:
> On Tue, Jun 25, 2013 at 04:27:18PM +0530, navin patidar wrote:
>> On Tue, Jun 25, 2013, Greg KH <gregkh@linuxfoundation.org> said:
>>
>> > On Fri, Jun 21, 2013 at 03:01:04PM +0530, navin patidar wrote:
>> >> pr_warn() is preferred over pr_warning().
>> >
>> > And dev_warn() is preferred over both of them, can you convert the code
>> > to use that instead?
>> >
>>
>> struct device is not available in usbip_start_eh() which is required
>> for dev_warn().
>>
>> usbip_device's containers struct stub_device and struct vhci_device
>> both have member structure usb_device but inside usbip_start_eh(), it
>> is difficult to determine to which container struct usbip_device
>> belongs, thus container_of() can not be used here to get struct
>> usb_device.
>
> Then the code should be reworked in order to be able to properly
> determine that.
>
struct usbip_device has enum type usbip_side variable which can be
used to determine container of usbip_device.
I should have looked usbip_device struct more carefully.
sorry for previous wrong info.
regards,
--navin-patidar
^ permalink raw reply [flat|nested] 5+ messages in thread
* [PATCH] staging: usbip: replace pr_warning() with pr_warn()
@ 2013-06-21 9:31 navin patidar
2013-06-24 22:33 ` Greg KH
0 siblings, 1 reply; 5+ messages in thread
From: navin patidar @ 2013-06-21 9:31 UTC (permalink / raw)
To: gregkh, mfm; +Cc: linux-usb, devel, linux-kernel, navin patidar
pr_warn() is preferred over pr_warning().
Signed-off-by: navin patidar <navinp@cdac.in>
---
drivers/staging/usbip/usbip_event.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/staging/usbip/usbip_event.c b/drivers/staging/usbip/usbip_event.c
index 82123be..64933b9 100644
--- a/drivers/staging/usbip/usbip_event.c
+++ b/drivers/staging/usbip/usbip_event.c
@@ -85,7 +85,7 @@ int usbip_start_eh(struct usbip_device *ud)
ud->eh = kthread_run(event_handler_loop, ud, "usbip_eh");
if (IS_ERR(ud->eh)) {
- pr_warning("Unable to start control thread\n");
+ pr_warn("Unable to start control thread\n");
return PTR_ERR(ud->eh);
}
--
1.7.10.4
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2013-06-26 6:42 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2013-06-25 10:57 [PATCH] staging: usbip: replace pr_warning() with pr_warn() navin patidar
2013-06-25 14:54 ` Greg KH
-- strict thread matches above, loose matches on Subject: below --
2013-06-26 6:42 navin patidar
2013-06-21 9:31 navin patidar
2013-06-24 22:33 ` Greg KH
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
Powered by JetHome