• Bjorn Helgaas's avatar
    rtc: fall back to requesting only the ports we actually use · 9626f1f1
    Bjorn Helgaas authored
    Firmware like PNPBIOS or ACPI can report the address space consumed by the
    RTC.  The actual space consumed may be less than the size (RTC_IO_EXTENT)
    assumed by the RTC driver.
    
    The PNP core doesn't request resources yet, but I'd like to make it do so.
    If/when it does, the RTC_IO_EXTENT request may fail, which prevents the RTC
    driver from loading.
    
    Since we only use the RTC index and data registers at RTC_PORT(0) and
    RTC_PORT(1), we can fall back to requesting just enough space for those.
    
    If the PNP core requests resources, this results in typical I/O port usage
    like this:
    
        0070-0073 : 00:06		<-- PNP device 00:06 responds to 70-73
          0070-0071 : rtc		<-- RTC driver uses only 70-71
    
    instead of the current:
    
        0070-0077 : rtc		<-- RTC_IO_EXTENT == 8
    Signed-off-by: default avatarBjorn Helgaas <bjorn.helgaas@hp.com>
    Cc: Alessandro Zummo <a.zummo@towertech.it>
    Cc: David Brownell <david-b@pacbell.net>
    Cc: Ralf Baechle <ralf@linux-mips.org>
    Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
    Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
    9626f1f1
Name
Last commit
Last update
..
acpi Loading commit data...
asm-alpha Loading commit data...
asm-arm Loading commit data...
asm-avr32 Loading commit data...
asm-blackfin Loading commit data...
asm-cris Loading commit data...
asm-frv Loading commit data...
asm-generic Loading commit data...
asm-h8300 Loading commit data...
asm-ia64 Loading commit data...
asm-m32r Loading commit data...
asm-m68k Loading commit data...
asm-m68knommu Loading commit data...
asm-mips Loading commit data...
asm-parisc Loading commit data...
asm-powerpc Loading commit data...
asm-ppc Loading commit data...
asm-s390 Loading commit data...
asm-sh Loading commit data...
asm-sh64 Loading commit data...
asm-sparc Loading commit data...
asm-sparc64 Loading commit data...
asm-um Loading commit data...
asm-v850 Loading commit data...
asm-x86 Loading commit data...
asm-xtensa Loading commit data...
crypto Loading commit data...
keys Loading commit data...
linux Loading commit data...
math-emu Loading commit data...
media Loading commit data...
mtd Loading commit data...
net Loading commit data...
pcmcia Loading commit data...
rdma Loading commit data...
rxrpc Loading commit data...
scsi Loading commit data...
sound Loading commit data...
video Loading commit data...
xen Loading commit data...
Kbuild Loading commit data...