diff mbox

mmc: tmio: eliminate unused variable 'mmc' warning

Message ID 1312354138.14329.1.camel@phoenix (mailing list archive)
State New, archived
Headers show

Commit Message

axel lin Aug. 3, 2011, 6:48 a.m. UTC
Fix below compile warning:
  CC      drivers/mmc/host/tmio_mmc.o
drivers/mmc/host/tmio_mmc.c: In function 'tmio_mmc_suspend':
drivers/mmc/host/tmio_mmc.c:30: warning: unused variable 'mmc'
drivers/mmc/host/tmio_mmc.c: In function 'tmio_mmc_resume':
drivers/mmc/host/tmio_mmc.c:45: warning: unused variable 'mmc'

Signed-off-by: Axel Lin <axel.lin@gmail.com>
---
 drivers/mmc/host/tmio_mmc.c |    2 --
 1 files changed, 0 insertions(+), 2 deletions(-)

Comments

Guennadi Liakhovetski Aug. 3, 2011, 7:26 a.m. UTC | #1
On Wed, 3 Aug 2011, Axel Lin wrote:

> Fix below compile warning:
>   CC      drivers/mmc/host/tmio_mmc.o
> drivers/mmc/host/tmio_mmc.c: In function 'tmio_mmc_suspend':
> drivers/mmc/host/tmio_mmc.c:30: warning: unused variable 'mmc'
> drivers/mmc/host/tmio_mmc.c: In function 'tmio_mmc_resume':
> drivers/mmc/host/tmio_mmc.c:45: warning: unused variable 'mmc'
> 
> Signed-off-by: Axel Lin <axel.lin@gmail.com>

Good for 3.1, do we also push such "harmless" compiler warning fixes to 
stable?

Acked-by: Guennadi Liakhovetski <g.liakhovetski@gmx.de>

Thanks
Guennadi

> ---
>  drivers/mmc/host/tmio_mmc.c |    2 --
>  1 files changed, 0 insertions(+), 2 deletions(-)
> 
> diff --git a/drivers/mmc/host/tmio_mmc.c b/drivers/mmc/host/tmio_mmc.c
> index 8d185de..44a9668 100644
> --- a/drivers/mmc/host/tmio_mmc.c
> +++ b/drivers/mmc/host/tmio_mmc.c
> @@ -27,7 +27,6 @@
>  static int tmio_mmc_suspend(struct platform_device *dev, pm_message_t state)
>  {
>  	const struct mfd_cell *cell = mfd_get_cell(dev);
> -	struct mmc_host *mmc = platform_get_drvdata(dev);
>  	int ret;
>  
>  	ret = tmio_mmc_host_suspend(&dev->dev);
> @@ -42,7 +41,6 @@ static int tmio_mmc_suspend(struct platform_device *dev, pm_message_t state)
>  static int tmio_mmc_resume(struct platform_device *dev)
>  {
>  	const struct mfd_cell *cell = mfd_get_cell(dev);
> -	struct mmc_host *mmc = platform_get_drvdata(dev);
>  	int ret = 0;
>  
>  	/* Tell the MFD core we are ready to be enabled */
> -- 
> 1.7.4.1
> 
> 
> 

---
Guennadi Liakhovetski, Ph.D.
Freelance Open-Source Software Developer
http://www.open-technology.de/
--
To unsubscribe from this list: send the line "unsubscribe linux-mmc" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Chris Ball Aug. 3, 2011, 12:55 p.m. UTC | #2
Hi,

On Wed, Aug 03 2011, Guennadi Liakhovetski wrote:
> On Wed, 3 Aug 2011, Axel Lin wrote:
>
>> Fix below compile warning:
>>   CC      drivers/mmc/host/tmio_mmc.o
>> drivers/mmc/host/tmio_mmc.c: In function 'tmio_mmc_suspend':
>> drivers/mmc/host/tmio_mmc.c:30: warning: unused variable 'mmc'
>> drivers/mmc/host/tmio_mmc.c: In function 'tmio_mmc_resume':
>> drivers/mmc/host/tmio_mmc.c:45: warning: unused variable 'mmc'
>> 
>> Signed-off-by: Axel Lin <axel.lin@gmail.com>
>
> Good for 3.1, do we also push such "harmless" compiler warning fixes to 
> stable?
>
> Acked-by: Guennadi Liakhovetski <g.liakhovetski@gmx.de>

Pushed for 3.1, thanks.  I don't think this is appropriate for stable.

- Chris.
Ian Molton Aug. 27, 2011, 7:02 p.m. UTC | #3
On Wed, 2011-08-03 at 08:55 -0400, Chris Ball wrote:
> > Good for 3.1, do we also push such "harmless" compiler warning fixes
> to 
> > stable?
> >
> > Acked-by: Guennadi Liakhovetski <g.liakhovetski@gmx.de>
> 
> Pushed for 3.1, thanks.  I don't think this is appropriate for stable.

Why on earth not? its obviously correct...

--
To unsubscribe from this list: send the line "unsubscribe linux-mmc" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Chris Ball Aug. 28, 2011, 6:20 p.m. UTC | #4
Hi Ian,

On Sat, Aug 27 2011, Ian Molton wrote:
> On Wed, 2011-08-03 at 08:55 -0400, Chris Ball wrote:
>> > Good for 3.1, do we also push such "harmless" compiler warning fixes
>> > to stable?
>> >
>> > Acked-by: Guennadi Liakhovetski <g.liakhovetski@gmx.de>
>> 
>> Pushed for 3.1, thanks.  I don't think this is appropriate for stable.
>
> Why on earth not? its obviously correct...

Because the rules for stable@ consist of more than the patch being
obviously correct.

You seem to have chosen one stable@ rule that this patch meets, and
ignored the other nine which it mostly does not meet:

Documentation/stable_kernel_rules.txt:
 - It must fix a real bug that bothers people (not a, "This could be a
   problem..." type thing).
 - It must fix a problem that causes a build error (but not for
   things marked CONFIG_BROKEN), an oops, a hang, data corruption,
   a real security issue, or some "oh, that's not good" issue.
   In short, something critical.
 - It cannot contain any "trivial" fixes in it (spelling changes,
   whitespace cleanups, etc).

Thanks,

- Chris.
diff mbox

Patch

diff --git a/drivers/mmc/host/tmio_mmc.c b/drivers/mmc/host/tmio_mmc.c
index 8d185de..44a9668 100644
--- a/drivers/mmc/host/tmio_mmc.c
+++ b/drivers/mmc/host/tmio_mmc.c
@@ -27,7 +27,6 @@ 
 static int tmio_mmc_suspend(struct platform_device *dev, pm_message_t state)
 {
 	const struct mfd_cell *cell = mfd_get_cell(dev);
-	struct mmc_host *mmc = platform_get_drvdata(dev);
 	int ret;
 
 	ret = tmio_mmc_host_suspend(&dev->dev);
@@ -42,7 +41,6 @@  static int tmio_mmc_suspend(struct platform_device *dev, pm_message_t state)
 static int tmio_mmc_resume(struct platform_device *dev)
 {
 	const struct mfd_cell *cell = mfd_get_cell(dev);
-	struct mmc_host *mmc = platform_get_drvdata(dev);
 	int ret = 0;
 
 	/* Tell the MFD core we are ready to be enabled */