Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753080AbbHVDHz (ORCPT ); Fri, 21 Aug 2015 23:07:55 -0400 Received: from mail-vk0-f51.google.com ([209.85.213.51]:36802 "EHLO mail-vk0-f51.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751560AbbHVDHx (ORCPT ); Fri, 21 Aug 2015 23:07:53 -0400 MIME-Version: 1.0 In-Reply-To: <1440079144-26461-8-git-send-email-ygardi@codeaurora.org> References: <1440079144-26461-1-git-send-email-ygardi@codeaurora.org> <1440079144-26461-8-git-send-email-ygardi@codeaurora.org> Date: Sat, 22 Aug 2015 12:07:52 +0900 Message-ID: Subject: Re: [PATCH v2 7/8] scsi: ufs-qcom: add debug prints for test bus From: Akinobu Mita To: Yaniv Gardi Cc: 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" Content-Type: text/plain; charset=UTF-8 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1258 Lines: 33 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? > + 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-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/