From patchwork Tue Sep 12 00:56:52 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Damien Le Moal X-Patchwork-Id: 13380580 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 11387CA0ECD for ; Tue, 12 Sep 2023 03:00:22 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S241288AbjILDAY (ORCPT ); Mon, 11 Sep 2023 23:00:24 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:53420 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S241068AbjILDAL (ORCPT ); Mon, 11 Sep 2023 23:00:11 -0400 Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 0FBA81A39AA; Mon, 11 Sep 2023 18:32:26 -0700 (PDT) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 344EDC3279E; Tue, 12 Sep 2023 00:57:23 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1694480244; bh=RyHmMaIW31a4d+xQxAGJ7MmlzJA+9IxnDZMnTwbIx84=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=N0KIh4kBarEdhyaKiuMmbysdK2d4mzT95Il8/aK0Nuj4JgRFlbHXiU/bO142iRABT 5dcekb5H8CyPBDQK7Tny4UJq2Z4dEs/qATkoeV/hcGDIyVTzxkaOggrgze3ROJOG3r DK3QPi4STcd9v4cEnuBoXubolPYYVWtNgRgBFn9/4luVXFs2m6GVzsaWZs+XmifSlI I2uYiO19XjIt9Ds67d6KqkrWpwzwRDcEE8IBpwR6lJtuYvnLTRrQG6e2oOOHFlEof6 ftU4yurhLXgdr1k+7hPjTyFdnJjfVX8+7kE3ytEZKEuJti72RL4nPIFIJ18u7DE/Ts Vw+e1r+9yVd3w== From: Damien Le Moal To: linux-ide@vger.kernel.org Cc: linux-scsi@vger.kernel.org, "Martin K . Petersen" , John Garry , Rodrigo Vivi , Paul Ausbeck , Kai-Heng Feng , Joe Breuer Subject: [PATCH v2 18/21] ata: libata-sata: Improve ata_sas_slave_configure() Date: Tue, 12 Sep 2023 09:56:52 +0900 Message-ID: <20230912005655.368075-19-dlemoal@kernel.org> X-Mailer: git-send-email 2.41.0 In-Reply-To: <20230912005655.368075-1-dlemoal@kernel.org> References: <20230912005655.368075-1-dlemoal@kernel.org> MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: linux-scsi@vger.kernel.org Change ata_sas_slave_configure() to return the return value of ata_scsi_dev_config() to ensure that any error from that function is propagated to libsas. Signed-off-by: Damien Le Moal Reviewed-by: Hannes Reinecke Reviewed-by: John Garry --- drivers/ata/libata-sata.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/ata/libata-sata.c b/drivers/ata/libata-sata.c index 5d31c08be013..0748e9ea4f5f 100644 --- a/drivers/ata/libata-sata.c +++ b/drivers/ata/libata-sata.c @@ -1169,8 +1169,8 @@ EXPORT_SYMBOL_GPL(ata_sas_tport_delete); int ata_sas_slave_configure(struct scsi_device *sdev, struct ata_port *ap) { ata_scsi_sdev_config(sdev); - ata_scsi_dev_config(sdev, ap->link.device); - return 0; + + return ata_scsi_dev_config(sdev, ap->link.device); } EXPORT_SYMBOL_GPL(ata_sas_slave_configure);