Bug 35952 - BAR1 not assigned
Summary: BAR1 not assigned
Status: CLOSED CODE_FIX
Alias: None
Product: Drivers
Classification: Unclassified
Component: PCI (show other bugs)
Hardware: All Linux
: P1 normal
Assignee: drivers_pci@kernel-bugs.osdl.org
URL: https://lkml.org/lkml/2011/5/19/348
Keywords:
Depends on:
Blocks:
 
Reported: 2011-05-26 19:58 UTC by Bjorn Helgaas
Modified: 2012-06-13 15:06 UTC (History)
2 users (show)

See Also:
Kernel Version: 2.6.35
Subsystem:
Regression: Yes
Bisected commit-id:


Attachments

Description Bjorn Helgaas 2011-05-26 19:58:29 UTC
The following device worked with 2.6.27, but doesn't work with 2.6.35:

05:01.0 Unassigned class [ff00]: Eagle Technology PCI-703 Analog I/O Card (rev 5c)
       Flags: bus master, slow devsel, latency 32, IRQ 22
       Memory at 93b00000 (type 3, prefetchable) [size=2K]
       Memory at <unassigned> (type 3, prefetchable)

2.6.27:
  dmesg:
    PCI: 0000:05:01.0 reg 10 32bit mmio: [0, 7ff]
    PCI: 0000:05:01.0 reg 14 32bit mmio: [0, 7ff]

  /proc/iomem:
     93500000-935007ff : 0000:05:01.0
       93500000-935007ff : pci703drv
     93500800-93500fff : 0000:05:01.0
       93500800-93500fff : pci703drv

2.6.35:
  dmesg:
    pci 0000:05:01.0: BAR 0: assigned [mem 0x93b00000-0x93b007ff 64bit pref]
    /data/projects/eagle/edrelib/edrelib-2.6.7/drivers/edredaq/pci703/pci703.c - dev_alloc - pci703drv: BAR0 OK ([mem 0x93b00000-0x93b007ff 64bit pref])
    /data/projects/eagle/edrelib/edrelib-2.6.7/drivers/edredaq/pci703/pci703.c - dev_alloc - pci703drv: Memory address for card detected at BAR1 (0xe)
    /data/projects/eagle/edrelib/edrelib-2.6.7/drivers/edredaq/pci703/pci703.c - dev_alloc - pci703drv: No memory address for card detected at BAR1 ([??? 0x00000000 flags 0x0])
    /data/projects/eagle/edrelib/edrelib-2.6.7/drivers/edredaq/pci703/pci703.c - dev_probe - pci703drv: Failed to setup device.


Note that the device has an invalid type (3) for the memory BARs.  In 2.6.27, we treated them as two 32-bit BARs, but in 2.6.35, we treat it as one 64-bit BAR.

Complete dmesg logs are in the LKML thread (see URL above).
Comment 1 Florian Mickler 2011-08-08 08:15:37 UTC
A patch referencing this bug report has been merged in Linux v3.1-rc1:

commit 8d6a6a47636648754dc371b01228520a2adaf430
Author: Bjorn Helgaas <bhelgaas@google.com>
Date:   Tue Jun 14 13:04:29 2011 -0600

    PCI: treat mem BAR type "11" (reserved) as 32-bit, not 64-bit, BAR

Note You need to log in before you can comment on or make changes to this bug.