public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Jeff Oczek <jeffoczek@gmail.com>
To: Greg KH <gregkh@linuxfoundation.org>
Cc: devel@driverdev.osuosl.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH] staging: cxt1e1: Fix static symbol sparse warnings for global vars in linux.c
Date: Tue, 22 Jul 2014 16:56:59 -0400	[thread overview]
Message-ID: <20140722205658.GA7117@fofx> (raw)
In-Reply-To: <20140722201722.GA20515@kroah.com>

On Tue, Jul 22, 2014 at 01:17:22PM -0700, Greg KH wrote:
> On Tue, Jul 22, 2014 at 04:07:51PM -0400, Jeff Oczek wrote:
> > Put extern declarations in cxt1e1_common.h to reduce sparse warnings for linux.c:
> 
> I know you didn't name this variable, but wow, that's a horrid name for
> a global variable :)
> 
> Any way you could change this to first fix up the name of the variable
> to something a bit more "device-specific" first, before this patch?
> 
> Perhaps "cxt1e1_error_flag"?
> 
> > +extern int cxt1e1_max_mru;
> > +extern int cxt1e1_max_mtu;
> 
> These are fine.
> 
> > +extern int max_mtu_default;
> > +extern int max_txdesc_used;
> > +extern int max_txdesc_default;
> > +extern int max_rxdesc_used;
> > +extern int max_rxdesc_default;
> 
> Again, these are bad names, can you do the same thing here?
> 
> thanks,
> 
> greg k-h

Hi Greg,

max_txdesc_used and max_rxdesc_used are module parameters, 
is it ok to change them?  I'm quite new to this -- I don't know if that
would count as breaking userspace or not.

If not allowed, I could go the route of changing these less descriptive ones
to static in the main file and then make an assignment to the global vars
during the module init.

Or I can just leave the module params be and change the other globals.

Any of those sound good?

Thanks,
Jeff

  reply	other threads:[~2014-07-22 20:57 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-07-22 20:07 [PATCH] staging: cxt1e1: Fix static symbol sparse warnings for global vars in linux.c Jeff Oczek
2014-07-22 20:17 ` Greg KH
2014-07-22 20:56   ` Jeff Oczek [this message]
2014-07-22 21:23     ` Greg KH
2014-07-23  0:34 ` [PATCH v2 0/2] staging: cxt1e1: Fix ambiguous global var names, reduce sparse warnings Jeff Oczek
2014-07-23  0:34   ` [PATCH v2 1/2] staging: cxt1e1: Prefix ambiguous variable names with 'cxt1e1_' for clarity Jeff Oczek
2014-07-23  0:34     ` [PATCH v2 2/2] staging: cxt1e1: Fix static symbol sparse warnings for global vars in linux.c Jeff Oczek
2014-07-24  1:20     ` [PATCH v2 1/2] staging: cxt1e1: Prefix ambiguous variable names with 'cxt1e1_' for clarity 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=20140722205658.GA7117@fofx \
    --to=jeffoczek@gmail.com \
    --cc=devel@driverdev.osuosl.org \
    --cc=gregkh@linuxfoundation.org \
    --cc=linux-kernel@vger.kernel.org \
    /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