tech-kern archive

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

[patch] Attempting to bring arcmsr(4) up to date

I've taken a stab at bringing arcmsr(4) up to par with OpenBSD's arc(4)
driver which arcmsr(4) is a port of. arc/arcmsr is the driver for the
Areca line of RAID controllers. The arcmsr driver currently only
supports the Intel cards (Rev A), Areca introduced three further
revisions of hardware based on 2 generations of Marvell hardware (Rev B
& D) and finally LSI hardware (Rev C).

I currently have access to an Areca ARC-1882IX-24 and wanted to see
support for it in NetBSD so I set out to bring in the changes from OpenBSD.
With the patch[1] and r1.1300 of src/sys/dev/pci/pcidevs (& regen of
headers) it's possible to build a working driver which works on the
ARC-1882IX-24. I've managed to install & boot NetBSD from mine.
There is a caveat though, there is something not quite right with memory
allocation which results in over use & the kernel panics.
As a work around to get the driver "working", by reducing the tested
values from 3 down to 2 in arc_msgbuf()

if ((rlen > 3) && (rdone == 3)) {
	rlen = *(u_int16_t *)rwbuf;
	rlen = sizeof(struct arc_fw_bufhdr) + rlen + 1;

if ((rlen > 2) && (rdone == 2)) { ... }

Kernel output with change in place

I was wondering what the recommended workflow is for tracking down the
allocation issue?

I'd be interested in reports back on users of cards supported by the
existing driver to ensure there are not any further problems.


Home | Main Index | Thread Index | Old Index