Re: [linux-usb-devel] [PATCH] limit power budget on spitz

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

 



On Thursday 08 June 2006 2:22 pm, Richard Purdie wrote:
> On Thu, 2006-06-08 at 13:38 -0700, David Brownell wrote: 
> > > http://www.arm.linux.org.uk/developer/patches/viewpatch.php?id=3547/1
> > 
> > OK, I see now.  Simple enough, better than the original.  Go for it.
> > 
> > There was a PXA issue I was alluding to that's still open, though.
> > It's the way there's no selectivity about what platform devices are
> > registered ... even kernels running on boards where OHCI isn't hooked
> > up to anything will be registering an OHCI controller, as one of many
> > examples.  Won't affect this particular case, but in general that'd
> > be nice to see fixed.
> 
> As I understood the code, if you don't have platform_data set, it will
> abort in the probe function so it depends what you mean by register. An
> OHCI controller never gets created without platform_data.
> 
> You're right that the PXA platform device is always registered. FWIW,
> there is no platform in mainline that doesn't have OHCI present so this
> isn't a major problem at the moment.

Right.  OHCI was just an example though ... there are lots of other
platform drivers for PXA.  I'm not sure they all check for platform_data
before succeeding in their probe() methods.


> The easiest solution might be to move the ohci device registration into
> pxa_set_ohci_info (in pxa27x.c). I gave in and appended a patch (compile
> tested only so far).

Looked OK to me.

That's the kind of approach now used with OMAP and AT91, and which IMO
would be appropriate to use for most platform devices ... that is, don't
register devices that the board doesn't have.  One additional nuance:  if
the kernel doesn't have that driver configured, that's another reason not
to bother registering its device.

- Dave

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [email protected]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

[Index of Archives]     [Kernel Newbies]     [Netfilter]     [Bugtraq]     [Photo]     [Stuff]     [Gimp]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Video 4 Linux]     [Linux for the blind]     [Linux Resources]
  Powered by Linux