opengnsys_ipxe/src
Michael Brown 46c7f99c66 [hermon] Use correct alignment for doorbell records
Doorbell records are currently embedded within the completion queue
and receive work queue strucures, which are allocated using zalloc()
and so have an alignment guarantee of only sizeof(void*), i.e. four
bytes.  This is sufficient for the receive work queue, but not for the
completion queue, which requires an alignment guarantee of eight
bytes.

Though not guaranteed, it so happens that zalloc() will always return
a pointer that is exactly four bytes above a sixteen-byte boundary.
The completion queue doorbell record is therefore always misaligned,
and the value passed to the hardware via SW2HW_CQ is actually always
pointing to the page_offset value within the MTT descriptor (which
directly precedes the inline doorbell record).  Provided that the page
offset is greater than 0x100, this looks to the hardware like an
update_ci value of greater than 0x010000 (taking into account
endianness differences), and so the hardware will happily deliver more
than 0x010000 completions before stopping.  Hence this problem is
rarely observable.

Fix by allocating the doorbell records separately and using the
correct alignment constraints.

Signed-off-by: Michael Brown <mcb30@ipxe.org>
2010-09-12 22:46:01 +01:00
..
arch [multiboot] Reduce length of "Features" startup banner 2010-09-12 22:18:11 +01:00
bin Rename .cvsignore files to .gitignore 2007-06-09 22:57:00 +01:00
config [infiniband] Include SRP by default, but only for Infiniband builds 2010-09-12 22:26:44 +01:00
core [xfer] Add xfer_window_changed() 2010-09-05 03:12:17 +01:00
crypto [build] Rename gPXE to iPXE 2010-04-19 23:43:39 +01:00
doc [build] Rename gPXE to iPXE 2010-04-19 23:43:39 +01:00
drivers [hermon] Use correct alignment for doorbell records 2010-09-12 22:46:01 +01:00
hci [linux] Add command line arguments 2010-08-19 12:45:41 +01:00
image [ioapi] Move get_memmap() to the I/O API group 2010-08-16 16:54:03 +01:00
include [infiniband] Respond to CM disconnection requests 2010-09-12 22:32:02 +01:00
interface [linux] Add empty smbios 2010-08-19 12:38:34 +01:00
libgcc [build] Mark __intel_new_proc_init with __libgcc rather than cdecl 2009-08-03 15:56:10 +01:00
net [infiniband] Respond to CM disconnection requests 2010-09-12 22:32:02 +01:00
tests [ioapi] Move get_memmap() to the I/O API group 2010-08-16 16:54:03 +01:00
usr [libc] Enable automated extraction of error usage reports 2010-05-31 03:11:57 +01:00
util [efi] Fix the 32-bit version of elf2efi64 2010-07-21 12:41:41 +01:00
.gitignore [build] Add support for local configuration files 2010-03-26 19:07:22 +00:00
Makefile [build] Add tap.linux to "make everything" 2010-08-19 13:26:00 +01:00
Makefile.housekeeping [build] Provide %.fd0 build targets only for pcbios 2010-08-17 14:36:39 +01:00
doxygen.cfg [build] Remove PACKED macro 2010-05-29 23:49:47 +01:00