From patchwork Thu Sep 10 01:37:56 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Stanley Chu X-Patchwork-Id: 257677 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-11.1 required=3.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, HEADER_FROM_DIFFERENT_DOMAINS, INCLUDES_PATCH, MAILING_LIST_MULTI, MIME_BASE64_TEXT, SIGNED_OFF_BY, SPF_HELO_NONE, SPF_PASS, UNPARSEABLE_RELAY, URIBL_BLOCKED, USER_AGENT_GIT autolearn=unavailable autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 3F1FCC43461 for ; Thu, 10 Sep 2020 02:49:55 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 0141421D80 for ; Thu, 10 Sep 2020 02:49:54 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (1024-bit key) header.d=mediatek.com header.i=@mediatek.com header.b="pNzeSiPW" Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1730167AbgIJB7A (ORCPT ); Wed, 9 Sep 2020 21:59:00 -0400 Received: from mailgw02.mediatek.com ([210.61.82.184]:30403 "EHLO mailgw02.mediatek.com" rhost-flags-OK-FAIL-OK-FAIL) by vger.kernel.org with ESMTP id S1728631AbgIJBib (ORCPT ); Wed, 9 Sep 2020 21:38:31 -0400 X-UUID: 222f52f8355341d2b9647e654a8e4954-20200910 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=mediatek.com; s=dk; h=Content-Transfer-Encoding:Content-Type:MIME-Version:Message-ID:Date:Subject:CC:To:From; bh=/kpiSBfDpcyE748DN9WDHc2W37kjiStGnsyZ7yp56L0=; b=pNzeSiPWeWjfzL2aW5NgVC1CC5xJFh47nUNG/ao7Jr4fF26Upi8Z92/Ru5dqzsDH3Y3Bu9zECtlIadBCaB16X1ZaKvIbhmyVodLO4rsGWZ8eHf/zypE6R5id1YlJ43N8+DnqCDbvAnxw+NgElfozVwsak0Aivic3Dv22MMNOS1E=; X-UUID: 222f52f8355341d2b9647e654a8e4954-20200910 Received: from mtkcas07.mediatek.inc [(172.21.101.84)] by mailgw02.mediatek.com (envelope-from ) (Cellopoint E-mail Firewall v4.1.14 Build 0819 with TLSv1.2 ECDHE-RSA-AES256-SHA384 256/256) with ESMTP id 1348526883; Thu, 10 Sep 2020 09:38:01 +0800 Received: from mtkcas07.mediatek.inc (172.21.101.84) by mtkmbs02n2.mediatek.inc (172.21.101.101) with Microsoft SMTP Server (TLS) id 15.0.1497.2; Thu, 10 Sep 2020 09:37:58 +0800 Received: from mtksdccf07.mediatek.inc (172.21.84.99) by mtkcas07.mediatek.inc (172.21.101.73) with Microsoft SMTP Server id 15.0.1497.2 via Frontend Transport; Thu, 10 Sep 2020 09:37:58 +0800 From: Stanley Chu To: , , , , CC: , , , , , , , , , , , Stanley Chu Subject: [PATCH] scsi: ufs-mediatek: Fix build warnings with make W=1 Date: Thu, 10 Sep 2020 09:37:56 +0800 Message-ID: <20200910013756.11385-1-stanley.chu@mediatek.com> X-Mailer: git-send-email 2.18.0 MIME-Version: 1.0 X-TM-SNTS-SMTP: 38E1E23B3D021B9BE7FEBC5B0F21E00D3CD02EEAB16EADD8D4E73E28F58D18842000:8 X-MTK: N Sender: linux-scsi-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-scsi@vger.kernel.org Fix build warnings with make W=1 as below, 1. >> drivers/scsi/ufs/ufs-mediatek.c:116:22: warning: format '%d' expects >> argument of type 'int', but argument 4 has type 'long int' 2. CC [M] drivers/scsi/ufs/ufs-mediatek.o ../drivers/scsi/ufs/ufs-mediatek.c:749: error: Cannot parse struct or union! /** is used specifically with kernel-doc tool. As a quick fix by removing dubious /** in the comment block of struct ufs_hba_variant_ops ufs_hba_mtk_vops. Signed-off-by: Stanley Chu --- drivers/scsi/ufs/ufs-mediatek.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) -- 2.18.0 diff --git a/drivers/scsi/ufs/ufs-mediatek.c b/drivers/scsi/ufs/ufs-mediatek.c index 1a9133ac6efb..3ec44dfa2567 100644 --- a/drivers/scsi/ufs/ufs-mediatek.c +++ b/drivers/scsi/ufs/ufs-mediatek.c @@ -113,7 +113,7 @@ static void ufs_mtk_init_reset_control(struct ufs_hba *hba, { *rc = devm_reset_control_get(hba->dev, str); if (IS_ERR(*rc)) { - dev_info(hba->dev, "Failed to get reset control %s: %d\n", + dev_info(hba->dev, "Failed to get reset control %s: %ld\n", str, PTR_ERR(*rc)); *rc = NULL; } @@ -727,13 +727,13 @@ static void ufs_mtk_fixup_dev_quirks(struct ufs_hba *hba) ufshcd_fixup_dev_quirks(hba, ufs_mtk_dev_fixups); } -/** +/* * struct ufs_hba_mtk_vops - UFS MTK specific variant operations * * The variant operations configure the necessary controller and PHY * handshake during initialization. */ -static struct ufs_hba_variant_ops ufs_hba_mtk_vops = { +static const struct ufs_hba_variant_ops ufs_hba_mtk_vops = { .name = "mediatek.ufshci", .init = ufs_mtk_init, .setup_clocks = ufs_mtk_setup_clocks,