From mboxrd@z Thu Jan 1 00:00:00 1970 From: ygardi@codeaurora.org Subject: Re: [PATCH v2 7/8] scsi: ufs-qcom: add debug prints for test bus Date: Sun, 23 Aug 2015 08:54:11 -0000 Message-ID: References: <1440079144-26461-1-git-send-email-ygardi@codeaurora.org> <1440079144-26461-8-git-send-email-ygardi@codeaurora.org> Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7BIT Return-path: In-Reply-To: Sender: linux-kernel-owner@vger.kernel.org To: Akinobu Mita Cc: Yaniv Gardi , Rob Herring , Jej B , Paul Bolle , Christoph Hellwig , LKML , "linux-scsi@vger.kernel.org" , linux-arm-msm@vger.kernel.org, Santosh Y , linux-scsi-owner@vger.kernel.org, Subhash Jadavani , Gilad Broner , Dolev Raviv , Vinayak Holikatti , "James E.J. Bottomley" List-Id: linux-scsi@vger.kernel.org > 2015-08-20 22:59 GMT+09:00 Yaniv Gardi : > >> +static bool ufs_qcom_testbus_cfg_is_ok(struct ufs_qcom_host *host) >> +{ >> + if (host->testbus.select_major >= TSTBUS_MAX) { >> + dev_err(host->hba->dev, >> + "%s: UFS_CFG1[TEST_BUS_SEL} may not equal >> 0x%05X\n", >> + __func__, host->testbus.select_major); >> + return false; >> + } >> + >> + /* >> + * Not performing check for each individual select_major >> + * mappings of select_minor, since there is no harm in >> + * configuring a non-existent select_minor >> + */ >> + if (host->testbus.select_major > 0x1F) { > > select_minor should be checked instead of select_major here? you are correct. should be select_minor > >> + dev_err(host->hba->dev, >> + "%s: 0x%05X is not a legal testbus option\n", >> + __func__, host->testbus.select_minor); >> + return false; >> + } >> + >> + return true; >> +} > -- > To unsubscribe from this list: send the line "unsubscribe linux-scsi" in > the body of a message to majordomo@vger.kernel.org > More majordomo info at http://vger.kernel.org/majordomo-info.html >