DaemonForums  

Go Back   DaemonForums > OpenBSD > OpenBSD General

OpenBSD General Other questions regarding OpenBSD which do not fit in any of the categories below.

Reply
 
Thread Tools Display Modes
  #1   (View Single Post)  
Old 6th May 2011
fossala's Avatar
fossala fossala is offline
Real Name: David
Fdisk Soldier
 
Join Date: Feb 2011
Location: Cornwall, UK
Posts: 53
Thanked 0 Times in 0 Posts
Default Marvell 88SX5081 SATA.

I've got this raid controller and I am trying to work (just as a sata controller).
Here Is the controller from dmesg
Code:
"Marvell 88SX5081 SATA" rev 0x03 at pci3 dev 2 function 0 not configured
I've got 2xWD 1TB in at the moment and non are showing up.
I really dont't know where to go from here so any help would be fantastic.
Reply With Quote
  #2   (View Single Post)  
Old 6th May 2011
jggimi's Avatar
jggimi jggimi is offline
More noise than signal
 
Join Date: May 2008
Location: USA
Posts: 3,697
Thanked 214 Times in 189 Posts
Default

When your dmesg shows "not configured", this means the device was recognized by the kernel, but there is no matching driver available.
Reply With Quote
  #3   (View Single Post)  
Old 6th May 2011
shep shep is offline
ISO Quartermaster
 
Join Date: May 2008
Location: Dry and Dusty
Posts: 593
Thanked 9 Times in 9 Posts
Default

I took a quick glance at the supported hardware for openbsd and did not see the Marvell SATA controllers listed. I recently tried to get a Via VT 8237S controller to support more than one SATA drive in OpenBSD without sucess.

I had better luck putting FreeBSD on the machine and it looks like FreeBSD added Marvell SATA support recently (8,1 release)
http://forums.freebsd.org/showthread.php?t=9533
Reply With Quote
  #4   (View Single Post)  
Old 8th May 2011
fossala's Avatar
fossala fossala is offline
Real Name: David
Fdisk Soldier
 
Join Date: Feb 2011
Location: Cornwall, UK
Posts: 53
Thanked 0 Times in 0 Posts
Default

Any chance this will work? I found it here. http://www.webservertalk.com/message2133676.html
Code:
Index: dev/pci/ahci.c
 ========================================
===========================
RCS file: /cvs/src/sys/dev/pci/ahci.c,v
retrieving revision 1.130
diff -u -p -r1.130 ahci.c
--- dev/pci/ahci.c	2007/10/27 10:51:21	1.130
+++ dev/pci/ahci.c	2007/10/31 15:56:27
@@ -34,7 +34,7 @@
#include <dev/ata/atascsi.h>

/* change to AHCI_DEBUG for dmesg spam */
-#define NO_AHCI_DEBUG
+#define AHCI_DEBUG

#ifdef AHCI_DEBUG
#define DPRINTF(m, f...) do { if ((ahcidebug & (m)) == (m)) printf(f); 
} \
@@ -387,8 +387,9 @@ struct ahci_softc {
bus_dma_tag_t		sc_dmat;

int			sc_flags;
-#define AHCI_F_NO_NCQ			(1<<0)
-#define AHCI_F_NO_FER			(1<<1)
+#define AHCI_F_NO_NCQ		(1<<0)
+#define AHCI_F_NO_FR		(1<<1)
+#define AHCI_F_NO_CR		(1<<2)

u_int			sc_ncmds;

@@ -419,12 +420,28 @@ int			ahci_vt8251_attach(struct ahci_sof
struct pci_attach_args *);
int			ahci_ati_ixp600_attach(struct ahci_softc *,
struct pci_attach_args *);
+int			ahci_88se61xx_attach(struct ahci_softc *,
+			    struct pci_attach_args *);

static const struct ahci_device ahci_devices[] = {
{  PCI_VENDOR_VIATECH,	PCI_PRODUCT_VIATECH_
VT8251_SATA,
ahci_no_match,	ahci_vt8251_attach },
{  PCI_VENDOR_ATI,	PCI_PRODUCT_ATI_IXP_SATA
_600,
-	    NULL,		ahci_ati_ixp600_attach }
+	    NULL,		ahci_ati_ixp600_attach },
+	{  PCI_VENDOR_MARVELL,	PCI_PRODUCT_MARVELL_
88SE6111,
+	    NULL,		ahci_88se61xx_attach },
+	{  PCI_VENDOR_MARVELL,	PCI_PRODUCT_MARVELL_
88SE6120,
+	    NULL,		ahci_88se61xx_attach },
+	{  PCI_VENDOR_MARVELL,	PCI_PRODUCT_MARVELL_
88SE6121,
+	    NULL,		ahci_88se61xx_attach },
+	{  PCI_VENDOR_MARVELL,	PCI_PRODUCT_MARVELL_
88SE6122,
+	    NULL,		ahci_88se61xx_attach },
+	{  PCI_VENDOR_MARVELL,	PCI_PRODUCT_MARVELL_
88SE6140,
+	    NULL,		ahci_88se61xx_attach },
+	{  PCI_VENDOR_MARVELL,	PCI_PRODUCT_MARVELL_
88SE6141,
+	    NULL,		ahci_88se61xx_attach },
+	{  PCI_VENDOR_MARVELL,	PCI_PRODUCT_MARVELL_
88SE6145,
+	    NULL,		ahci_88se61xx_attach }
};

int			ahci_pci_match(struct device *, void *, void *);
@@ -554,8 +571,16 @@ ahci_vt8251_attach(struct ahci_softc *sc

int
ahci_ati_ixp600_attach(struct ahci_softc *sc, struct pci_attach_args *pa)
+{
+	sc->sc_flags |= AHCI_F_NO_FR;
+
+	return (0);
+}
+
+ int
+ahci_88se61xx_attach(struct ahci_softc *sc, struct pci_attach_args *pa)
{
-	sc->sc_flags |= AHCI_F_NO_FER;
+	sc->sc_flags |= AHCI_F_NO_FR | AHCI_F_NO_CR | AHCI_F_NO_NCQ;

return (0);
}
@@ -911,6 +936,8 @@ ahci_port_alloc(struct ahci_softc *sc, u
goto freeport;
}

+	printf("preg=0x%x\n", cmd);
+
/* Allocate a CCB for each command slot */
ap->ap_ccbs = malloc(sizeof(struct ahci_ccb) * sc->sc_ncmds, M_DEVBUF,
M_NOWAIT | M_ZERO);
@@ -1014,6 +1041,9 @@ nomem:
DPRINTF(AHCI_D_VERBOSE, "%s: detected device on port %d\n",
DEVNAME(sc), port);

+	printf("preg=0x%x\n",
+	    ahci_pread(ap, AHCI_PREG_CMD) & ~AHCI_PREG_CMD_ICC);
+
/* Enable command transfers on port */
if (ahci_port_start(ap, 0)) {
printf("%s: failed to start command DMA on port %d, "
@@ -1084,8 +1114,7 @@ ahci_port_start(struct ahci_port *ap, in

/* Turn on FRE (and ST) */
r = ahci_pread(ap, AHCI_PREG_CMD) & ~AHCI_PREG_CMD_ICC;
-	if (!(ap->ap_sc->sc_flags & AHCI_F_NO_FER))
-		r |= AHCI_PREG_CMD_FRE;
+	r |= AHCI_PREG_CMD_FRE;
if (!fre_only)
r |= AHCI_PREG_CMD_ST;
ahci_pwrite(ap, AHCI_PREG_CMD, r);
@@ -1098,16 +1127,22 @@ ahci_port_start(struct ahci_port *ap, in
ap->ap_sc->sc_ccc_ports_cur);
}
#endif
+
+	printf("preg=0x%x\n",
+	    ahci_pread(ap, AHCI_PREG_CMD) & ~AHCI_PREG_CMD_ICC);

-	if (!(ap->ap_sc->sc_flags & AHCI_F_NO_FER)) {
+	if (!(ap->ap_sc->sc_flags & AHCI_F_NO_FR)) {
/* Wait for FR to come on */
if (ahci_pwait_set(ap, AHCI_PREG_CMD, AHCI_PREG_CMD_FR))
return (2);
}

-	/* Wait for CR to come on */
-	if (!fre_only && ahci_pwait_set(ap, AHCI_PREG_CMD, AHCI_PREG_CMD_CR))
-		return (1);
+	if (!(ap->ap_sc->sc_flags & AHCI_F_NO_CR)) {
+		/* Wait for CR to come on */
+		if (!fre_only && ahci_pwait_set(ap, AHCI_PREG_CMD,
+		    AHCI_PREG_CMD_CR))
+			return (1);
+	}

return (0);
}
Reply With Quote
  #5   (View Single Post)  
Old 8th May 2011
BSDfan666 BSDfan666 is offline
Real Name: N/A, this is the interweb.
Helpful companion
 
Join Date: Apr 2008
Location: Ontario, Canada
Posts: 2,223
Thanked 193 Times in 184 Posts
Default

That is a mailing list post (tech@) archived on a forum, did you read it? the changes add support for 88SE* based devices.. not 88SX*.

If the controller in question does support AHCI (..but messed up the standardized way of indicating this) it may be possible to force the driver to attach in a similar fashion.

I'd recommend checking the BIOS and seeing if the mode of the controller can be toggled, i.e: AHCI vs. IDE vs RAID mode.. if it's in RAID mode, OpenBSD usually won't attach to it.
Reply With Quote
  #6   (View Single Post)  
Old 8th May 2011
jggimi's Avatar
jggimi jggimi is offline
More noise than signal
 
Join Date: May 2008
Location: USA
Posts: 3,697
Thanked 214 Times in 189 Posts
Default

There was no follow up posting to this 3.5 year old tech@ thread. More importantly the Marvell product attachment code was never added to sys/dev/pci/ahci.c.

To put this into historical perspective, the request for testers was posted four weeks before 4.3 was locked down for -release testing.
Reply With Quote
  #7   (View Single Post)  
Old 8th May 2011
fossala's Avatar
fossala fossala is offline
Real Name: David
Fdisk Soldier
 
Join Date: Feb 2011
Location: Cornwall, UK
Posts: 53
Thanked 0 Times in 0 Posts
Default

Quote:
Originally Posted by BSDfan666 View Post
I'd recommend checking the BIOS and seeing if the mode of the controller can be toggled, i.e: AHCI vs. IDE vs RAID mode.. if it's in RAID mode, OpenBSD usually won't attach to it.
The board doesn't do any form of hardware (fake or real) RAID. It's just a controller. I don't want to give up but it doesn't sound like I have any options.

I also tried it with FreeBSD and it kernel panics with the card in. I tried FreeNAS and that just corrupts my gpt on install then won't boot (on my scsi RAID card).

Starting to look like I will have to put debian
Reply With Quote
  #8   (View Single Post)  
Old 9th May 2011
BSDfan666 BSDfan666 is offline
Real Name: N/A, this is the interweb.
Helpful companion
 
Join Date: Apr 2008
Location: Ontario, Canada
Posts: 2,223
Thanked 193 Times in 184 Posts
Default

Doing some digging it seems these SATA controllers are proprietary and don't support the standard AHCI/PCIIDE interfaces at all and requires a "native" driver.

You can try adding the following to OpenBSD's pciide.c and hoping some basic semblance of SATA support is to be found.. but it's highly unlikely.
Code:
const struct pciide_product_desc pciide_marvell_products[] = {
    { PCI_PRODUCT_MARVELL_88SX5081,
      0,
      sata_chip_map
    },
};
FreeBSD indeed has a driver for this family of cards, mvs(4), but it would appear you've run into other problems.
Reply With Quote
  #9   (View Single Post)  
Old 9th May 2011
fossala's Avatar
fossala fossala is offline
Real Name: David
Fdisk Soldier
 
Join Date: Feb 2011
Location: Cornwall, UK
Posts: 53
Thanked 0 Times in 0 Posts
Default

Thanks I'm trying that now. Not getting my hopes up though.
I cannot afford to get one now but can anyone recommend me a pci-x card for the future?
Reply With Quote
Old 9th May 2011
fossala's Avatar
fossala fossala is offline
Real Name: David
Fdisk Soldier
 
Join Date: Feb 2011
Location: Cornwall, UK
Posts: 53
Thanked 0 Times in 0 Posts
Default

Nope no luck.
Reply With Quote
Old 9th May 2011
BSDfan666 BSDfan666 is offline
Real Name: N/A, this is the interweb.
Helpful companion
 
Join Date: Apr 2008
Location: Ontario, Canada
Posts: 2,223
Thanked 193 Times in 184 Posts
Default

When you buy a card, look for one that mentions PCIIDE/AHCI support.. or perhaps has marketing phrases like "plug and play" or "no drivers required", supporting Mac OS X may also be a good indicator.

You can get some simple cards for less then $20, and most places have return policies, you might have to buy a few different cards until you find one that works.
Reply With Quote
Old 9th May 2011
fossala's Avatar
fossala fossala is offline
Real Name: David
Fdisk Soldier
 
Join Date: Feb 2011
Location: Cornwall, UK
Posts: 53
Thanked 0 Times in 0 Posts
Default

http://mail-index.netbsd.org/netbsd-...8/14/0010.html
This makes me think I could use netbsd but when I load it up its not detected. Is there any other steps I would need to take. Sorry I have never used NetBSD before.
Reply With Quote
Old 10th May 2011
BSDfan666 BSDfan666 is offline
Real Name: N/A, this is the interweb.
Helpful companion
 
Join Date: Apr 2008
Location: Ontario, Canada
Posts: 2,223
Thanked 193 Times in 184 Posts
Default

No.. OpenBSD also has a similar file for PCI product ID's, it is required for more "humanized" output of detected devices.

That does not indicate support.
Reply With Quote
Reply

Tags
raid sata controller

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Marvell 88E8038 ethernet adaptor doesn't work with NetBSD 5, even with ACPI disabled GullibleJones NetBSD General 2 13th December 2009 10:55 AM
FreeBSD 8 and marvell yukon 88e8057 latorion FreeBSD General 5 29th November 2009 11:35 PM
E-SATA? PatrickBaer OpenBSD General 28 5th October 2008 11:41 PM
Marvell Yukon driver cannot load with ACPI enabled GullibleJones FreeBSD General 2 15th September 2008 02:58 PM
Using FreeBSD Marvell Driver vi5in FreeBSD General 0 12th May 2008 11:16 PM


All times are GMT. The time now is 12:28 AM.


Powered by vBulletin® Version 3.8.4
Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.
Content copyright © 2007-2010, the authors
Daemon image copyright ©1988, Marshall Kirk McKusick