You are not logged in.
I have been weeks trying to sort this problem. My SATA controller (Marvell 88SE6141) is not supported out of the box, so after some research and taking a look at the manufacturer's driver, all that is needed is this line added in the achi.c file of the kernel,
{ PCI_VDEVICE(MARVELL, 0x6141), board_ahci_mv }, /* Marvell 88SE6141 */The solution to this seems to 'patch' the kernel with a copy of the achi.c file adding the above line. However so far I have not managed to do so, plus this would mean having to patch every single kernel update.
Is there a simpler way? Patching the kernel seems such a 'big' job for such a small thing, the driver already is in the system, the only thing needed is to tell the system to use the right driver for this 'device'. Is there a way to bind/assign the PCI_VDEVICE to the driver that needs to use, such as a boot script/command?
Last edited by JimCAT (2018-10-17 20:53:33)
Offline
Welcome to the arch linux forums JimCAT.
What has been the issue with patching https://github.com/torvalds/linux/blob/ … hci.c#L528 ?
If after you have tested that such a patch works correctly you can then ask for support to be integrated upstream.
Offline
So far I have been unsuccessful in creating my own patched kernel, still trying though. Yet I do not have a lot of knowledge on these things, last time I had to patch my kernel was over 10 years ago.
That's why I was wondering if there was a different way to bind/assign/link this driver other than patching the kernel.
The line stated above, in theory, worked for other people, so I tried to request this to be added to the main Linux kernel a while ago (see git pull) but it turns out that the kernel is not updated using git but stone-age mailing lists, to which I have written about the update a couple of times, yet ignored; likely because the request was incorrectly formatted (as apparently, I need to read a whole encyclopedia before writing to them to add a simple line of code). Sorry for my sarcasm.
I guess, my question here is if there is a way other than the kernel patch to do this. If so, I would love to try it. If there is not, I shall carry on banging my head with the kernel patch and -if necessary- open a different thread to debug my problems with that.
Offline
I am not aware of a dynamic binding mechanism for the ahci module.
diff --git a/drivers/ata/ahci.c b/drivers/ata/ahci.c
index b2b9eba1d214..ff5e1d6bcd71 100644
--- a/drivers/ata/ahci.c
+++ b/drivers/ata/ahci.c
@@ -525,6 +525,7 @@ static const struct pci_device_id ahci_pci_tbl[] = {
{ PCI_VDEVICE(STMICRO, 0xCC06), board_ahci }, /* ST ConneXt */
/* Marvell */
+ { PCI_VDEVICE(MARVELL, 0x6141), board_ahci_mv }, /* 6141 */
{ PCI_VDEVICE(MARVELL, 0x6145), board_ahci_mv }, /* 6145 */
{ PCI_VDEVICE(MARVELL, 0x6121), board_ahci_mv }, /* 6121 */
{ PCI_DEVICE(PCI_VENDOR_ID_MARVELL_EXT, 0x9123),Patching_packages#Applying_patches for the linux package it is even simpler.
Ensure the file has the .patch extension add the patch to the sources array, run `updpkgsums` to add a checksum entry for it the PKGBUILD then run makepkg.
Offline
Thanks for this. I managed to compile the kernel with this, but the driver didn't work for Marvell 88SE6141. I tried with both board_ahci_mv and board_ahci just in case, but no luck. With the board_ahci_mv driver, it finds the controller well but no disks are shown on it.
I guess it will be time to abandon and find a different solution. Thanks for the help anyway ![]()
Last edited by JimCAT (2018-11-05 11:58:23)
Offline