Received: by 2002:a25:8b91:0:0:0:0:0 with SMTP id j17csp996042ybl; Sat, 18 Jan 2020 16:15:05 -0800 (PST) X-Google-Smtp-Source: APXvYqzBoWC5zteTUGdqa9XOkKBHEdoZiomj/I1/V2eaOFfOSHYJ3/lp6wnaqa0RIAf/Kds8USmQ X-Received: by 2002:a05:6830:1607:: with SMTP id g7mr11203468otr.320.1579392904868; Sat, 18 Jan 2020 16:15:04 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1579392904; cv=none; d=google.com; s=arc-20160816; b=nNbRq14XHEyvpBTOhX4VHr7m7sCkwyFGZ34viuo4T5gl246RUxJ3xGcAkML06o7hKz EuD6LOiQst27Ea/Bkta3BRy9cWbQXnbBC8ykzX9nC/RjKbkAbaHPB8oJTrod83HiHxKC hEgqiIvt957iVd5h+vS7Qw1C3J1UnJGK+yOn+wfrYgiGRDr9fbguqyUmN5QpXVEG03IO Zp+GbAhgRVujmWohqCb60thJ7u+Udglre0Axk29NNLD23xuZztbJKprbpFz0S1UPkJUY hUIvHVb8eEE22nyqk6n4hy+qyP13pJfShrmNFJhBm0ttbXvrm5Hz83NisemlUvFGLc+4 fG+g== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:references:in-reply-to:message-id:date :subject:cc:to:from:dkim-signature; bh=sELIAc9JYznk8gLukGl5sh9ks34HnlMIU1NIlCV4wTE=; b=WfTZPNFie9eLZvUlDcB1sXH+qn0QQ+cBiPc6RxZciDEUtJ03Ak/dVhLLrnSvr4Cep7 uXUTmuzbaB1yAR0qyveYvMwubJNvrmbUzo9p+QOMd0TNiHE2sM0I0ZBMc8uRqtzuaAKG KIRrBpBCGWgyVJ/fO17fLv3WEwF06cVyBWv5rhuL9gaGbrI08JnxkSE3/3xmHV1zgGQy IMrDw/yq3YjBxApZXSIiD9fynDtONF+albIUq6JGut8drbDtqY5hBAkAUjOAoSN5i6PV nuhCw1xZRs96zHUGTcHk5CWxLlgbl1mK3qj+BymBe0ebFAgiOADDB9/G6lj6gDaQA8Tq by1w== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=iW7zEuSY; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id d23si15954619oij.270.2020.01.18.16.14.52; Sat, 18 Jan 2020 16:15:04 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=iW7zEuSY; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727162AbgASAOC (ORCPT + 99 others); Sat, 18 Jan 2020 19:14:02 -0500 Received: from mail-wm1-f68.google.com ([209.85.128.68]:39182 "EHLO mail-wm1-f68.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727012AbgASAOB (ORCPT ); Sat, 18 Jan 2020 19:14:01 -0500 Received: by mail-wm1-f68.google.com with SMTP id 20so11160523wmj.4; Sat, 18 Jan 2020 16:14:00 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=sELIAc9JYznk8gLukGl5sh9ks34HnlMIU1NIlCV4wTE=; b=iW7zEuSYXDcEN+aUn69no6y2/t2qEqG9s+uaKRUQD46IoxNzuGFgHN42ldtJYynCOA Zd25bcAcApbUAw/X+z/RjlTe3MJQg+ww+lNOBXZnGjm9RUXwOGfDqth68LygsxIS3y6I 7936Jf6am0ix7igdQDhcVTZlC0Or20mSDXuGtW21PQ6lh51cgxmDy0f7S6J1cOVo9R8v Obh6IoH/Hd2TEaRsCDcn/b2ayLW8Q9fhRrepcc0NoU6b/wy2qy7uYeCk6f8D9/XIZLfE j/19KzQVXAmMH8nRaG6t+oCiU2H5Dc3+Rsht9NzZcAc0fPdVVaTD3MfrDeN9zZfz9vyJ Pu3Q== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=sELIAc9JYznk8gLukGl5sh9ks34HnlMIU1NIlCV4wTE=; b=t6eo3X9O6oUROf/nH0eeMnzT0xWkrXh6zYnst+zw1OIsgMtKcD4LN+CzP/o9v2L4IE 6qMTovGFiEEdKsL/yUOjfM+C6WGBQMLAATAZEBFfu623V9hAunjzxrc2TL3oeorMW+KB aq2c0+hkf/Zpuw4LpjB6ZEMVK+u+7Ym5jr25MWSiH3k11wm9kYv1Os9EOE39rU7uV6tA /IvDrpvz+ysbc3f+5whDzhrjGtYfIjMG4eDusPpIRDlw+7yrreI1rlibt8ZqqrIUxr3E SqEaE447uQ+4xmmb/H9e43jsDtWdcde7DkTpcSVbtQ0aGPvoBYThc+S4Rx99b+v53JgM Rv4g== X-Gm-Message-State: APjAAAX+OR6Iy/bOpwhgkowMatdjBi5Yk2dsAPSddA+VZVBxSP5OSyJF zxC8CbyXJbCxZpUsxJLB86I= X-Received: by 2002:a7b:c1d8:: with SMTP id a24mr11801469wmj.130.1579392839387; Sat, 18 Jan 2020 16:13:59 -0800 (PST) Received: from localhost.localdomain (ip5f5bee3c.dynamic.kabel-deutschland.de. [95.91.238.60]) by smtp.gmail.com with ESMTPSA id i8sm42177432wro.47.2020.01.18.16.13.58 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 18 Jan 2020 16:13:58 -0800 (PST) From: Bean Huo To: alim.akhtar@samsung.com, avri.altman@wdc.com, asutoshd@codeaurora.org, jejb@linux.ibm.com, martin.petersen@oracle.com, stanley.chu@mediatek.com, beanhuo@micron.com, bvanassche@acm.org, tomas.winkler@intel.com, cang@codeaurora.org Cc: linux-scsi@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH v3 1/8] scsi: ufs: Fix ufshcd_probe_hba() reture value in case ufshcd_scsi_add_wlus() fails Date: Sun, 19 Jan 2020 01:13:20 +0100 Message-Id: <20200119001327.29155-2-huobean@gmail.com> X-Mailer: git-send-email 2.17.1 In-Reply-To: <20200119001327.29155-1-huobean@gmail.com> References: <20200119001327.29155-1-huobean@gmail.com> Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Bean Huo A non-zero error value likely being returned by ufshcd_scsi_add_wlus() in case of failure of adding the WLs, but ufshcd_probe_hba() doesn't use this value, and doesn't report this failure to upper caller. This patch is to fix this issue. Fixes: 2a8fa600445c ("ufs: manually add well known logical units") Reviewed-by: Asutosh Das Signed-off-by: Bean Huo --- drivers/scsi/ufs/ufshcd.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/drivers/scsi/ufs/ufshcd.c b/drivers/scsi/ufs/ufshcd.c index bea036ab189a..9a9085a7bcc5 100644 --- a/drivers/scsi/ufs/ufshcd.c +++ b/drivers/scsi/ufs/ufshcd.c @@ -7032,7 +7032,8 @@ static int ufshcd_probe_hba(struct ufs_hba *hba) ufshcd_init_icc_levels(hba); /* Add required well known logical units to scsi mid layer */ - if (ufshcd_scsi_add_wlus(hba)) + ret = ufshcd_scsi_add_wlus(hba); + if (ret) goto out; /* Initialize devfreq after UFS device is detected */ -- 2.17.1