From: Greg KH <gregkh@suse.de>
To: Elina <epasheva@sierrawireless.com>
Cc: rfiler@sierrawireless.com, linux-kernel@vger.kernel.org
Subject: Re: [PATCH 001/003] USB: serial: sierra driver performance improvements
Date: Mon, 6 Apr 2009 18:01:34 -0700 [thread overview]
Message-ID: <20090407010134.GB2839@suse.de> (raw)
In-Reply-To: <1239062754.10120.36.camel@Linuxdev3>
On Mon, Apr 06, 2009 at 05:05:54PM -0700, Elina wrote:
> +int sierra_suspend(struct usb_serial *serial, pm_message_t message)
> +{
> + printk(KERN_ERR "################################%s\n", __func__);
> +
> + return 0;
> +}
> +
> +int sierra_resume(struct usb_serial *serial)
> +{
> + printk(KERN_ERR "################################%s\n", __func__);
> +
> + return 0;
> +}
What are these changes for? What are they supposed to do becides annoy
any user who happens to want to suspend/resume their system with your
driver and device loaded?
> static struct usb_driver sierra_driver = {
> .name = "sierra",
> .probe = usb_serial_probe,
> .disconnect = usb_serial_disconnect,
> + .suspend = usb_serial_suspend,
> + .resume = usb_serial_resume,
Please keep the formatting the same wherever possible (hint, like
here...)
> struct sierra_port_private {
> @@ -360,7 +385,12 @@ static int sierra_write(struct tty_struc
> unsigned long flags;
> unsigned char *buffer;
> struct urb *urb;
> - int status;
> + size_t writesize = min((size_t)count, (size_t)MAX_TRANSFER);
There is a min_t() macro if you need to cast the type, like you did
here, please use that instead.
> static void sierra_indat_callback(struct urb *urb)
> @@ -735,6 +764,8 @@ static struct usb_serial_driver sierra_d
> .attach = sierra_startup,
> .shutdown = sierra_shutdown,
> .read_int_callback = sierra_instat_callback,
> + .suspend = sierra_suspend,
> + .resume = sierra_resume,
Same formatting issue here as above.
> - printk(KERN_INFO KBUILD_MODNAME ": " DRIVER_VERSION ":"
> - DRIVER_DESC "\n");
> -
> + printk(KERN_ERR "################################%s\n", __func__);
> return 0;
This is not an ok change.
> failed_driver_register:
> @@ -763,6 +792,7 @@ failed_device_register:
>
> static void __exit sierra_exit(void)
> {
> + printk(KERN_ERR "################################%s\n", __func__);
And neither is this.
It looks like you left your debugging code in here :(
thanks,
greg k-h
next prev parent reply other threads:[~2009-04-07 1:06 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-04-07 0:05 [PATCH 001/003] USB: serial: sierra driver performance improvements Elina
2009-04-07 0:58 ` Greg KH
2009-04-07 1:01 ` Greg KH [this message]
2009-04-07 11:13 ` Alan Cox
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=20090407010134.GB2839@suse.de \
--to=gregkh@suse.de \
--cc=epasheva@sierrawireless.com \
--cc=linux-kernel@vger.kernel.org \
--cc=rfiler@sierrawireless.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