Hi, I tested the kernel-2.6.24.2-3.fc8 (downloaded the x86_64 build directly) on my laptop. Hal detects two batteries because it looks in sysfs and in procfs for the battery info. I tryed to apply the patch from the hal-list which causes hal to not look in procfs but in sysfs only when the sysfs info is available. The problem with this is that the info in sysfs is broken (capcity 3.0 Wh etc while the procfs info is correct 45Wh). I would suggest to set CONFIG_ACPI_SYSFS_POWER to n because the procfs info already provides this data for userspace and does not report broken values.
On 02/16/2008 06:53 AM, drago01 wrote:> Hi, > I tested the kernel-2.6.24.2-3.fc8 (downloaded the x86_64 build > directly) on my laptop. > Hal detects two batteries because it looks in sysfs and in procfs for > the battery info. I tryed to apply the patch from the hal-list which > causes hal to not look in procfs but in sysfs only when the sysfs info > is available. The problem with this is that the info in sysfs is broken > (capcity 3.0 Wh etc while the procfs info is correct 45Wh). > I would suggest to set CONFIG_ACPI_SYSFS_POWER to n because the procfs > info already provides this data for userspace and does not report broken > values. >We should be enabling either one or the other, not both. For Fedora 9 maybe it should be the sysfs interface if it works. For 8 it should be only procfs to be backwards compatible. I''ll do that.
On Sun, Feb 17, 2008 at 09:08:02PM -0500, Chuck Ebbert wrote: > On 02/16/2008 06:53 AM, drago01 wrote: > > Hi, > > I tested the kernel-2.6.24.2-3.fc8 (downloaded the x86_64 build > > directly) on my laptop. > > Hal detects two batteries because it looks in sysfs and in procfs for > > the battery info. I tryed to apply the patch from the hal-list which > > causes hal to not look in procfs but in sysfs only when the sysfs info > > is available. The problem with this is that the info in sysfs is broken > > (capcity 3.0 Wh etc while the procfs info is correct 45Wh). > > I would suggest to set CONFIG_ACPI_SYSFS_POWER to n because the procfs > > info already provides this data for userspace and does not report broken > > values. > > > > We should be enabling either one or the other, not both. > > For Fedora 9 maybe it should be the sysfs interface if it works. > > For 8 it should be only procfs to be backwards compatible. I''ll do that. Yeah, you need a new enough hal aparently, which I guess f8 didn''t have. F9 should be safe to be using just the sysfs stuff. Dave -- http://www.codemonkey.org.uk
On Feb 18, 2008 6:06 AM, Dave Jones <davej@redhat.com> wrote:> > On Sun, Feb 17, 2008 at 09:08:02PM -0500, Chuck Ebbert wrote: > > On 02/16/2008 06:53 AM, drago01 wrote: > > > Hi, > > > I tested the kernel-2.6.24.2-3.fc8 (downloaded the x86_64 build > > > directly) on my laptop. > > > Hal detects two batteries because it looks in sysfs and in procfs for > > > the battery info. I tryed to apply the patch from the hal-list which > > > causes hal to not look in procfs but in sysfs only when the sysfs info > > > is available. The problem with this is that the info in sysfs is broken > > > (capcity 3.0 Wh etc while the procfs info is correct 45Wh). > > > I would suggest to set CONFIG_ACPI_SYSFS_POWER to n because the procfs > > > info already provides this data for userspace and does not report broken > > > values. > > > > > > > We should be enabling either one or the other, not both. > > > > For Fedora 9 maybe it should be the sysfs interface if it works. > > > > For 8 it should be only procfs to be backwards compatible. I''ll do that. > > Yeah, you need a new enough hal aparently, which I guess f8 didn''t have. > F9 should be safe to be using just the sysfs stuff.I have not tested rawhide on a laptop yet, but it seems that rawhide still uses hal-0.5.10 (which is also the lastest upstream); on F8 this one was not working for me. But David might know more....
On Mon, 2008-02-18 at 11:23 +0100, drago01 wrote:> > Yeah, you need a new enough hal aparently, which I guess f8 didn''t have. > > F9 should be safe to be using just the sysfs stuff. > > I have not tested rawhide on a laptop yet, but it seems that rawhide > still uses hal-0.5.10 (which is also the lastest upstream); on F8 this > one was not working for me. > But David might know more....The fixes should be in git (maybe, when I checked a few months ago some bits were missing from sysfs); I''ll test and put a newer snapshot in later this week. David
On Sun, Feb 17, 2008 at 09:08:02PM -0500, Chuck Ebbert wrote:> On 02/16/2008 06:53 AM, drago01 wrote: > > Hi, > > I tested the kernel-2.6.24.2-3.fc8 (downloaded the x86_64 build > > directly) on my laptop. > > Hal detects two batteries because it looks in sysfs and in procfs for > > the battery info. I tryed to apply the patch from the hal-list which > > causes hal to not look in procfs but in sysfs only when the sysfs info > > is available. The problem with this is that the info in sysfs is broken > > (capcity 3.0 Wh etc while the procfs info is correct 45Wh). > > I would suggest to set CONFIG_ACPI_SYSFS_POWER to n because the procfs > > info already provides this data for userspace and does not report broken > > values. > > > > We should be enabling either one or the other, not both. >my logic was people could be running rawhide kernels on old userspace (i do this, for instance.)> For Fedora 9 maybe it should be the sysfs interface if it works. >i don''t really see a harm in having both.> For 8 it should be only procfs to be backwards compatible. I''ll do that. >agreed, don''t want to tempt fate on f8... cheers, kyle> _______________________________________________ > Fedora-kernel-list mailing list > Fedora-kernel-list@redhat.com > https://www.redhat.com/mailman/listinfo/fedora-kernel-list >
On Mon, Feb 18, 2008 at 11:25:40AM -0500, Kyle McMartin wrote: > On Sun, Feb 17, 2008 at 09:08:02PM -0500, Chuck Ebbert wrote: > > On 02/16/2008 06:53 AM, drago01 wrote: > > > Hi, > > > I tested the kernel-2.6.24.2-3.fc8 (downloaded the x86_64 build > > > directly) on my laptop. > > > Hal detects two batteries because it looks in sysfs and in procfs for > > > the battery info. I tryed to apply the patch from the hal-list which > > > causes hal to not look in procfs but in sysfs only when the sysfs info > > > is available. The problem with this is that the info in sysfs is broken > > > (capcity 3.0 Wh etc while the procfs info is correct 45Wh). > > > I would suggest to set CONFIG_ACPI_SYSFS_POWER to n because the procfs > > > info already provides this data for userspace and does not report broken > > > values. > > > > > > > We should be enabling either one or the other, not both. > > > > my logic was people could be running rawhide kernels on old userspace > (i do this, for instance.) actually that''s a really good point, given how bad rawhide has been lately at being installable. I do the same thing btw (f9 kernel on f8) because of this, and hadn''t picked up on this breakage because my laptop runs f8 kernel. > > For Fedora 9 maybe it should be the sysfs interface if it works. > i don''t really see a harm in having both. I imagine that eventually someone upstream will make the decision a no-brainer by removing the proc stuff. Not shipping it does mean that nothing new will start depending on it. (Unlikely I know, but still...) > > For 8 it should be only procfs to be backwards compatible. I''ll do that. > agreed, don''t want to tempt fate on f8... ACK. Dave -- http://www.codemonkey.org.uk
On Mon, Feb 18, 2008 at 11:48:20AM -0500, Dave Jones wrote:> > > For Fedora 9 maybe it should be the sysfs interface if it works. > > i don''t really see a harm in having both. > > I imagine that eventually someone upstream will make the decision a no-brainer > by removing the proc stuff. Not shipping it does mean that nothing new will > start depending on it. (Unlikely I know, but still...) >This is true. The patch I submitted to hal (I think it''s in git, but not sure it has made it into a release or Fedora) preferentially selects sysfs over procfs, so hopefully that will at least encourage people to fix the shortcomings, if any, in the sysfs interfaces. :/ cheers, Kyle