From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S934061AbcIPLQ4 (ORCPT ); Fri, 16 Sep 2016 07:16:56 -0400 Received: from mx2.suse.de ([195.135.220.15]:33463 "EHLO mx2.suse.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1759269AbcIPLQl (ORCPT ); Fri, 16 Sep 2016 07:16:41 -0400 Subject: Re: TRIM/UNMAP/DISCARD via ATA Passthrough To: "Jason A. Donenfeld" , "Martin K. Petersen" References: Cc: linux-scsi@vger.kernel.org, LKML From: Hannes Reinecke Message-ID: <5af202ea-a632-28c2-515f-c361e27de5da@suse.de> Date: Fri, 16 Sep 2016 13:16:35 +0200 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:45.0) Gecko/20100101 Thunderbird/45.3.0 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 09/15/2016 10:52 PM, Jason A. Donenfeld wrote: > Hi Martin, > > On Thu, Sep 15, 2016 at 6:07 PM, Martin K. Petersen >> But how do they signal that ATA passthrough is possible? Is there an ATA >> Information VPD page? Is REPORT SUPPORTED OPERATION CODES supported? >> >> We need really solid discovery data before we can entertain enabling >> something like this. > > `sg_opcodes` said invalid request, so I think there isn't REPORT > SUPPORTED OPERATION CODES, and `sg_vpd -p ai` came up illegal too. > > However, sg_sat_identify worked reliably, which means a solid way of > probing this would be to send IDENTIFY DEVICE ATA via SG_ATA_16 or > SG_ATA_12. > > Let me know and I can give you access to the hardware if you're curious. > Sadly, that's not sufficient. linux is not the only provider of an SATL (mpt3sas being the most prominent other one). And while they might support ATA_12/ATA_16, there is no indication that you can pass DSM TRIM that way. Cheers, Hannes -- Dr. Hannes Reinecke zSeries & Storage hare@suse.de +49 911 74053 688 SUSE LINUX Products GmbH, Maxfeldstr. 5, 90409 Nürnberg GF: J. Hawn, J. Guild, F. Imendörffer, HRB 16746 (AG Nürnberg)