Re: [PATCH 1/2] applesmc: Use PnP rather than hardcoding resources and devices

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Thu, Dec 16, 2010 at 09:00:18AM -0800, Guenter Roeck wrote:

> I am having trouble applying this patch to my -next tree. The driver there
> (and in the official -next tree) has subtle differences to your version.
> What tree is your patch based on ? Can you rebase it to the -next tree and resubmit ?

My mistake - I'd pulled the patches from LKML, but it looks like there 
was a later version of one or two.

> Couple of comments below; not necessarily complete, since I can not apply the patch.
> I hope Henrik can comment on the merits of the patch itself, ie if it is known to work
> with all systems.

> > +struct pnp_dev *pdev;
> > +struct applesmc_pnp_device *pnp_device;
> > +
> Please make those variables static.

Oops! Yup.

> Just wondering ...  applesmc_pnp_device doesn't seem to be necessary. 
> Why not just use the global variable directly if you have it anyway ?

This ended up left over as part of an attempt to get rid of the 
globals...

> > +       pnp_set_drvdata(dev, applesmc_pnp_device);
> > +
> 
> ... but then since you assign it to drvdata, can you get rid of the global variable 
> and use pnp_get_drvdata() whereever it is needed instead ?

But then I ran into some awkward issue and decided to leave it. And then 
failed to clean everything up. I'll repost without that.

-- 
Matthew Garrett | mjg59@xxxxxxxxxxxxx

_______________________________________________
lm-sensors mailing list
lm-sensors@xxxxxxxxxxxxxx
http://lists.lm-sensors.org/mailman/listinfo/lm-sensors


[Index of Archives]     [Linux Kernel]     [Linux Hardware Monitoring]     [Linux USB Devel]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [Yosemite Backpacking]

  Powered by Linux