Received: by 2002:a25:683:0:0:0:0:0 with SMTP id 125csp530570ybg; Wed, 10 Jun 2020 07:08:33 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwDtdxSnG4ufyCBAX2wWkMPBIsx9LJtRJXHUwM0wvqdsOC5wOSZ8TddIY6taR36OslOsC3I X-Received: by 2002:a17:906:2ec6:: with SMTP id s6mr3789312eji.532.1591798113035; Wed, 10 Jun 2020 07:08:33 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1591798113; cv=none; d=google.com; s=arc-20160816; b=BaKDLugojArkVHHKeDKsdenPMbjQomef96TseXdMH6r7y0Ezog/GmiBqRL3y+zGBMI r8SsvioVAgixh5VNxa2abJ5jbI9Nhg+ffqbopooVDqymwJI58iIdaJeLAXxb7iNHjRM4 KhX+aDLBkdWqDakPOMyqmPlP3DDQMq2RFgxee5bw4QITuMv2uodQYnQRbdxf9aJARB3D Q1FvD7qiG3lXqI1BTPKhkdwIlPmtEib+AH86o1sqj4dGEqixj/yG8sRvmJeMaO9Dr/GM hF1WOQGmkFYYD3qJ9x/aHFp3Fdjjrf2jAb9e5wqMUqDRhNv4r7sH6GS66zJD3Nhvv5GF cjVA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :references:in-reply-to:date:cc:to:from:subject:message-id :dkim-signature; bh=hJE0N3sQWCYDZd2K2v2aUUyDKr9zLBCD5upNatqrvns=; b=JicwRXwsiZuwqZKxuyvA3rry3rEo5Jn8eLAonfMYZqnH6DustLMTlnuwjIeLqHC8b3 EhMV0pIphS9nDmxIyc4IMctTVAF64zHzmuiqVQW8yVp3QoPRLbFsPDs9gSWuECQH1w+k o178IopiT+K5qb4VqYp8yWJLJRwG5QSGS4m0lH4unPwpL4LyXBDy9huDUSSgRfMZvBj0 5C6kBJzHROkH4e+3BBKL7XLxH7DF0R/Ucfuhlo3c5y8peM8/KewyWfZwRfLYS1SrEino PmWbziKm1kc7YjLbXlXR5Dh1xsvVYCZyANzF7kTpK6SxR0MsfwZJ/n18ceWsDQkM0LFX LQmw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=jR8yqW9f; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 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. [23.128.96.18]) by mx.google.com with ESMTP id rp9si31126ejb.718.2020.06.10.07.08.08; Wed, 10 Jun 2020 07:08:33 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=jR8yqW9f; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 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 S1727070AbgFJJGh (ORCPT + 99 others); Wed, 10 Jun 2020 05:06:37 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:41778 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726219AbgFJJGg (ORCPT ); Wed, 10 Jun 2020 05:06:36 -0400 Received: from mail-wr1-x443.google.com (mail-wr1-x443.google.com [IPv6:2a00:1450:4864:20::443]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 0DF4AC03E96B; Wed, 10 Jun 2020 02:06:36 -0700 (PDT) Received: by mail-wr1-x443.google.com with SMTP id j10so1348646wrw.8; Wed, 10 Jun 2020 02:06:35 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=message-id:subject:from:to:cc:date:in-reply-to:references :mime-version:content-transfer-encoding; bh=hJE0N3sQWCYDZd2K2v2aUUyDKr9zLBCD5upNatqrvns=; b=jR8yqW9faRx6jDMBWUQM1MyeETZVp0RnCXVrTV5Pk8g6XuyfnGiWZ4NbZRovA3ynH6 MmRNUuJt2ad8LZ48QSkOAoIShCgD/eAwqLG/VSduq9d0RAfWektR8fgdBAaKN8E5eK3A jOts4wfXb7yoI3bvsZsLXbSQqZxp3KaVGPhQslBFe9s3YK/xDHhFdtEthHFGLtgDprkm 9DyKB85qz6h5INhtmYatqzEsWFbpnU3VwI+/SU8kC79j5O74k0g2z0cird/uNKY0fijr 9COnJJ7FFrJs0xAgeM8o7YMlqfYUNZD1fnCxQp5fUXdY95Ws9aguIMEnOXXdZ53ft0Pq OzGA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:message-id:subject:from:to:cc:date:in-reply-to :references:mime-version:content-transfer-encoding; bh=hJE0N3sQWCYDZd2K2v2aUUyDKr9zLBCD5upNatqrvns=; b=JBbHoUVN6ZekB4qK00CdMDvxrcPm5QjpjDwSTzKp1u+fwrAd5lsg/OOiX/v9GDfSiu 3UU/KYPOhjzKGQAqLFKHNeklyOyaBhcUJbqfqivpfCfE3LuZUhoyUHiObMKZfow9MiRz 86+M1j4YpbP5kHO6a8OXzVfF38iSKAwFBBb09pPeF3XIw2AgrwZ87VwiCk1wEG+U5nDk N2A5YZ0+f5r6qSFwriWvYvzE7oxQ+ZJFob/uEiQInXUbWQSs2z5K0wNyLzw1rA+ccPq6 IcT7l3PfWmTu63AiszuPtn7xSRjg4JHB6Zrcshqu/PyorzPeOH2kdwYaUDHIiGJktf5Q Z3MQ== X-Gm-Message-State: AOAM533aaMDEYuirZ+BqYvhyMVtOuWaRLzg93tbtJOlZ8673R5s4kqhV woAUBN/uHT1Kjvatye3t8VQ= X-Received: by 2002:a5d:6150:: with SMTP id y16mr2648501wrt.219.1591779994792; Wed, 10 Jun 2020 02:06:34 -0700 (PDT) Received: from ubuntu-laptop ([2a01:598:b90a:8f5:dd1:7313:78f9:539b]) by smtp.googlemail.com with ESMTPSA id b19sm6618937wmj.0.2020.06.10.02.06.31 (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Wed, 10 Jun 2020 02:06:34 -0700 (PDT) Message-ID: Subject: Re: [PATCH v1 1/2] scsi: ufs: Add DELAY_BEFORE_LPM quirk for Micron devices From: Bean Huo To: Stanley Chu , linux-scsi@vger.kernel.org, martin.petersen@oracle.com, avri.altman@wdc.com, alim.akhtar@samsung.com, jejb@linux.ibm.com, asutoshd@codeaurora.org Cc: beanhuo@micron.com, cang@codeaurora.org, matthias.bgg@gmail.com, bvanassche@acm.org, linux-mediatek@lists.infradead.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, kuohong.wang@mediatek.com, peter.wang@mediatek.com, chun-hung.wu@mediatek.com, andy.teng@mediatek.com, chaotian.jing@mediatek.com, cc.chou@mediatek.com Date: Wed, 10 Jun 2020 11:06:26 +0200 In-Reply-To: <20200610053645.19975-2-stanley.chu@mediatek.com> References: <20200610053645.19975-1-stanley.chu@mediatek.com> <20200610053645.19975-2-stanley.chu@mediatek.com> Content-Type: text/plain; charset="UTF-8" X-Mailer: Evolution 3.28.5-0ubuntu0.18.04.2 Mime-Version: 1.0 Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed, 2020-06-10 at 13:36 +0800, Stanley Chu wrote: > It is confirmed that Micron device needs DELAY_BEFORE_LPM > quirk to have a delay before VCC is powered off. So add Micron > vendor ID and this quirk for Micron devices. > > Signed-off-by: Stanley Chu Reviewed-by: Bean Huo Thanks, Bean > --- > drivers/scsi/ufs/ufs_quirks.h | 1 + > drivers/scsi/ufs/ufshcd.c | 2 ++ > 2 files changed, 3 insertions(+) > > diff --git a/drivers/scsi/ufs/ufs_quirks.h > b/drivers/scsi/ufs/ufs_quirks.h > index e3175a63c676..e80d5f26a442 100644 > --- a/drivers/scsi/ufs/ufs_quirks.h > +++ b/drivers/scsi/ufs/ufs_quirks.h > @@ -12,6 +12,7 @@ > #define UFS_ANY_VENDOR 0xFFFF > #define UFS_ANY_MODEL "ANY_MODEL" > > +#define UFS_VENDOR_MICRON 0x12C > #define UFS_VENDOR_TOSHIBA 0x198 > #define UFS_VENDOR_SAMSUNG 0x1CE > #define UFS_VENDOR_SKHYNIX 0x1AD > diff --git a/drivers/scsi/ufs/ufshcd.c b/drivers/scsi/ufs/ufshcd.c > index 04b79ca66fdf..dea4fddf9332 100644 > --- a/drivers/scsi/ufs/ufshcd.c > +++ b/drivers/scsi/ufs/ufshcd.c > @@ -216,6 +216,8 @@ ufs_get_desired_pm_lvl_for_dev_link_state(enum > ufs_dev_pwr_mode dev_state, > > static struct ufs_dev_fix ufs_fixups[] = { > /* UFS cards deviations table */ > + UFS_FIX(UFS_VENDOR_MICRON, UFS_ANY_MODEL, > + UFS_DEVICE_QUIRK_DELAY_BEFORE_LPM), > UFS_FIX(UFS_VENDOR_SAMSUNG, UFS_ANY_MODEL, > UFS_DEVICE_QUIRK_DELAY_BEFORE_LPM), > UFS_FIX(UFS_VENDOR_SAMSUNG, UFS_ANY_MODEL, > -- > 2.18.0