From owner-freebsd-current@freebsd.org Thu Oct 27 17:39:31 2016 Return-Path: Delivered-To: freebsd-current@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 1F66AC24CF8 for ; Thu, 27 Oct 2016 17:39:31 +0000 (UTC) (envelope-from cipher_nl@hotmail.com) Received: from COL004-OMC4S15.hotmail.com (col004-omc4s15.hotmail.com [65.55.34.217]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-SHA384 (256/256 bits)) (Client CN "*.outlook.com", Issuer "Microsoft IT SSL SHA2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id DC2EC837 for ; Thu, 27 Oct 2016 17:39:30 +0000 (UTC) (envelope-from cipher_nl@hotmail.com) Received: from EUR02-AM5-obe.outbound.protection.outlook.com ([65.55.34.201]) by COL004-OMC4S15.hotmail.com over TLS secured channel with Microsoft SMTPSVC(7.5.7601.23008); Thu, 27 Oct 2016 10:38:24 -0700 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=hotmail.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version; bh=M4vO0ysqzRJrYl7Gyfwjl1Dlw9mwOeFlpnKfC4QbHRw=; b=CyIkdWhrY0SrcKsQ4qznxTMDYW0Ik3k4fZsbw6j68NFbZc83nbw2yFEQy5+W7MCMb92nNgR2BjN6TReWqsJ4krk3vP0aMlYoQYrZKob3z3l7gzdY2Z5LBsXMsgdj5yXKZFz05dMFpcqSsMFh6lHMg/qEQK+uoOnICIe2X9fN4OfKTblJstdmInb2qstRsnNec7XB75wb0b4X8+gMmfrM7J6y1wPtkJacEGVJ9TaK34482XWpFiPth4Lx73DERga2g1FtdCnxWatMwdlUrvSi8XQnjbHAYKvexf1595kKwTNM8A3nnSvJUv2GHT8kDYdzQPOY/oUiFD8eEPd2zWOaFw== Received: from VE1EUR02FT046.eop-EUR02.prod.protection.outlook.com (10.152.12.51) by VE1EUR02HT094.eop-EUR02.prod.protection.outlook.com (10.152.12.181) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384_P384) id 15.1.679.5; Thu, 27 Oct 2016 17:38:21 +0000 Received: from DB5PR08MB0664.eurprd08.prod.outlook.com (10.152.12.54) by VE1EUR02FT046.mail.protection.outlook.com (10.152.12.247) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384_P384) id 15.1.679.5 via Frontend Transport; Thu, 27 Oct 2016 17:38:21 +0000 Received: from DB5PR08MB0664.eurprd08.prod.outlook.com ([10.169.33.14]) by DB5PR08MB0664.eurprd08.prod.outlook.com ([10.169.33.14]) with mapi id 15.01.0693.009; Thu, 27 Oct 2016 17:38:21 +0000 From: "D. E" To: "freebsd-current@freebsd.org" Subject: DeLock 10x SATA AHCI controller not working properly Thread-Topic: DeLock 10x SATA AHCI controller not working properly Thread-Index: AQHSMHi2h1QoeoJ6dUiYUf0D2GT3oQ== Date: Thu, 27 Oct 2016 17:38:21 +0000 Message-ID: Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: authentication-results: hotmail.com; dkim=none (message not signed) header.d=none;hotmail.com; dmarc=none action=none header.from=hotmail.com; x-ms-exchange-messagesentrepresentingtype: 1 x-tmn: [R/Gj1AYaQ1PNjBwHBOCyCxYy8Je2731n] x-eopattributedmessage: 0 x-microsoft-exchange-diagnostics: 1; VE1EUR02HT094; 6:HhTytqft+a6pzBfdcQYiQQ/y9sAbCdvUfn3n+CCTS4yLj0KP9xO4Vt9b6k47CBBytx0p7ZKsuxfO6x22m8d4/e/TPEVWOeAcGgYH79nw5K+KfQUQA4LkWJyx4TeNanq5GV1PsuswDoeayM7KisrQu7voRrdTJE8N9/WbTDVifT30rO5mFsIovKjzBFd9ZcOGx8f48xbUCndDFyXU7c/HeOcGbirv1tgXpMMNUPTvqeAA7z1MRv9xm+EF/RjT/mDB3GpTmKn0tv72tXN8hLVdfYMSYNKyOzC9xvvqOGFmkXog9S/lrU5b1FlTN0YK13v7; 5:8ku8ascntqy3iRz301wdx8IS9xSOFrsoJFNjUnAGp80ER6RgfII7y70C2UgtcYf+i5ry3Ltd3IAsfRrk4nMRYBXTzvKjpC8o6k99uQtehbwuHR1vPeWHWu2KhVCeX5E5/QHjtSvwJrPsXzGFts4YVw==; 24:9SpS+6Akb8qt0+ePx7a+ZlhYCcHPTqcq75GYNiXSB7fz2M2LdCKzkAPFvr9N6L2HXZX/kcnxyOG9sWPo0GF2jnlvWkOOkduEty2CqIL5XPQ=; 7:yjdWoMG9vRAbl/BCrkJ5J3/mS1eBONBgho0Q6ROwkiF9x1WmLzIkp+xBjXMyXGAxSi0a7RcJMdz2zpyR4jZaIXfylf7vvgflqhnvk66CNpL0ks4gXd+cd2F5oZENEcnA7PQIPnmAhnCEHngMHPPcUJdBw3HR+iFsBUKI42d8ty5WSbwMdTh4C2T69IMMAbp6HipmKlNN0LLIHhPiI4uTjxaSf8lj0qhYOjDfTaifKac7a76NwsCaWl6wrmrQXdaTwve969iRkuPRQ35Gj8GflvADC1Db71qphK36j2HNgP3gJiH79uXMkoigIi2cc/Dr7NO0pI3ZjKegp85B4W+VwlzQHz232ou2pMLEVO5k07k= x-forefront-antispam-report: EFV:NLI; SFV:NSPM; SFS:(10019020)(98900003); DIR:OUT; SFP:1102; SCL:1; SRVR:VE1EUR02HT094; H:DB5PR08MB0664.eurprd08.prod.outlook.com; FPR:; SPF:None; LANG:en; x-ms-office365-filtering-correlation-id: 5ecad9fb-08c2-4585-7bdb-08d3fe900bd1 x-microsoft-antispam: UriScan:; BCL:0; PCL:0; RULEID:(1601124038)(1603103081)(1601125047); SRVR:VE1EUR02HT094; x-exchange-antispam-report-cfa-test: BCL:0; PCL:0; RULEID:(432015012)(82015046); SRVR:VE1EUR02HT094; BCL:0; PCL:0; RULEID:; SRVR:VE1EUR02HT094; x-forefront-prvs: 0108A997B2 spamdiagnosticoutput: 1:99 spamdiagnosticmetadata: NSPM Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-OriginatorOrg: hotmail.com X-MS-Exchange-CrossTenant-originalarrivaltime: 27 Oct 2016 17:38:21.5094 (UTC) X-MS-Exchange-CrossTenant-fromentityheader: Internet X-MS-Exchange-CrossTenant-id: 84df9e7f-e9f6-40af-b435-aaaaaaaaaaaa X-MS-Exchange-Transport-CrossTenantHeadersStamped: VE1EUR02HT094 X-OriginalArrivalTime: 27 Oct 2016 17:38:24.0085 (UTC) FILETIME=[EACFA050:01D23078] X-Mailman-Approved-At: Thu, 27 Oct 2016 18:15:09 +0000 X-BeenThere: freebsd-current@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: Discussions about the use of FreeBSD-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 27 Oct 2016 17:39:31 -0000 Dear list, I hope you guys can help me with my new AHCI controller that doesn't work w= ell with FreeBSD yet. *** Introduction I have bought this very neat $80 SATA AHCI controller: http://www.delock.co= m/produkte/G_89384/merkmale.html This controller is PCI-express 2.0 with 2 lanes, so 1GB/s bandwidth shared = across 10 ports. For just $80 this is a great deal! It is also VERY power e= fficient, unlike SAS adapters which can use up to 8W when doing nothing. Th= e controller itself it a 2-port Asmedia AHCI SATA controller with two port = multipliers on it. Thus, each 5 ports are sharing one SATA/600 link. It pus= hes beyond 900MB/s when fully utilised. The controller is detected by FreeBSD 11.0-RELEASE-p1 amd64 as a regular AH= CI controller. It appears to work, in that it detects the disks that are co= nnected to it and it can do I/O. *** The problem This controller generates various I/O errors and timeouts. But only in spec= ific circumstances, where I think that NCQ or simultaneous access is a fact= or. Because when i start a simple dd read command for each harddrive connec= ted to the controller, there are no errors or timeouts in the dmesg. But wh= en importing a pool, creating a pool or scrubbing a pool that is empty, tim= eouts and I/O errors are 100% reproducable in just a few seconds. This is a= fter dd commands have been running for hours straight without any hickup. In other words, I believe this controller needs some kind of quirk. The con= troller is reported to be working properly on Linux. *** What I already tried I tried disabling MSI and MSI-X interrupts. I tried disabling NCQ although = with limited effect: ZFS can be tuned to use one outstanding I/O, but I sti= ll got errors now and then. Is there any way of doing some easy quirks to localize the problem and also= get this controller working reliably, albeit slower? *** Example errors when working with ZFS: ahcich7: Timeout on slot 23 port 0 ahcich7: is 00000000 cs 00000000 ss 00000000 rs 00800000 tfd 50 serr 000000= 00 cmd 0004cf17 (ada9:ahcich7:0:0:0): READ_DMA. ACB: c8 00 00 ff 02 40 00 00 00 00 00 00 (ada9:ahcich7:0:0:0): CAM status: Command timeout (ada9:ahcich7:0:0:0): Retrying command ahcich17: Timeout on slot 30 port 0 ahcich17: is 00000000 cs 00000000 ss 00000000 rs 40000000 tfd 50 serr 00000= 000 cmd 0004c317 (aprobe0:ahcich17:0:0:0): SETFEATURES SET TRANSFER MODE. ACB: ef 03 00 00 0= 0 40 00 00 00 00 46 00 (aprobe0:ahcich17:0:0:0): CAM status: Command timeout (aprobe0:ahcich17:0:0:0): Retrying command *** Detection logs: # pciconf -lv ahci1@pci0:4:0:0: class=3D0x010601 card=3D0x10601b21 chip=3D0x06251b2= 1 rev=3D0x01 hdr=3D0x00 vendor =3D 'ASMedia Technology Inc.' class =3D mass storage subclass =3D SATA # dmesg pci4: on pcib4 ahci1: mem 0xfdafe000-0xfdafffff irq 16 at device 0.= 0 on pci4 ahci1: AHCI v1.31 with 12 6Gbps ports, Port Multiplier not supported ahcich6: at channel 0 on ahci1 ahcich7: at channel 1 on ahci1 ahcich10: at channel 4 on ahci1 ahcich11: at channel 5 on ahci1 ahcich12: at channel 6 on ahci1 ahcich13: at channel 7 on ahci1 ahcich14: at channel 8 on ahci1 ahcich15: at channel 9 on ahci1 ahcich16: at channel 10 on ahci1 ahcich17: at channel 11 on ahci1 # devinfo -r pci4 pcib4 bus numbers: 4 ahci1 Interrupt request lines: 0x109 pcib4 memory window: 0xfdafe000-0xfdafffff ahcich6 I/O memory addresses: 0xfdafe100-0xfdafe17f ahcich7 I/O memory addresses: 0xfdafe180-0xfdafe1ff ahcich10 I/O memory addresses: 0xfdafe300-0xfdafe37f ahcich11 I/O memory addresses: 0xfdafe380-0xfdafe3ff ahcich12 I/O memory addresses: 0xfdafe400-0xfdafe47f ahcich13 I/O memory addresses: 0xfdafe480-0xfdafe4ff ahcich14 I/O memory addresses: 0xfdafe500-0xfdafe57f ahcich15 I/O memory addresses: 0xfdafe580-0xfdafe5ff ahcich16 I/O memory addresses: 0xfdafe600-0xfdafe67f ahcich17 I/O memory addresses: 0xfdafe680-0xfdafe6ff PS. please click 'Reply All' when replying, since I am not subscribed to th= e list, meaning that I cannot easily reply on your reply unless you also se= nd it to my email directly, using 'Reply All'. Thanks!=