From patchwork Wed Apr 24 05:51:45 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: James Qian Wang X-Patchwork-Id: 10914157 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 81D521515 for ; Wed, 24 Apr 2019 05:51:53 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 672F628A00 for ; Wed, 24 Apr 2019 05:51:53 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 5401F28A59; Wed, 24 Apr 2019 05:51:53 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-5.2 required=2.0 tests=BAYES_00,MAILING_LIST_MULTI, RCVD_IN_DNSWL_MED autolearn=ham version=3.3.1 Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) (using TLSv1.2 with cipher DHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id AB43C28A00 for ; Wed, 24 Apr 2019 05:51:52 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 63A2689208; Wed, 24 Apr 2019 05:51:50 +0000 (UTC) X-Original-To: dri-devel@lists.freedesktop.org Delivered-To: dri-devel@lists.freedesktop.org Received: from EUR03-DB5-obe.outbound.protection.outlook.com (mail-eopbgr40049.outbound.protection.outlook.com [40.107.4.49]) by gabe.freedesktop.org (Postfix) with ESMTPS id 302ED89208 for ; Wed, 24 Apr 2019 05:51:48 +0000 (UTC) Received: from VE1PR08MB5006.eurprd08.prod.outlook.com (10.255.159.31) by VE1PR08MB5072.eurprd08.prod.outlook.com (20.179.29.150) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.1813.17; Wed, 24 Apr 2019 05:51:45 +0000 Received: from VE1PR08MB5006.eurprd08.prod.outlook.com ([fe80::6ca6:1d85:8903:90d7]) by VE1PR08MB5006.eurprd08.prod.outlook.com ([fe80::6ca6:1d85:8903:90d7%5]) with mapi id 15.20.1813.017; Wed, 24 Apr 2019 05:51:45 +0000 From: "james qian wang (Arm Technology China)" To: Liviu Dudau , "airlied@linux.ie" , Brian Starkey , "maarten.lankhorst@linux.intel.com" , "sean@poorly.run" Subject: [PATCH] drm/komeda: Mark the local functions as static Thread-Topic: [PATCH] drm/komeda: Mark the local functions as static Thread-Index: AQHU+mHMyYOfGpzbx0SuyD5V70fYFg== Date: Wed, 24 Apr 2019 05:51:45 +0000 Message-ID: <20190424055108.19390-1-james.qian.wang@arm.com> Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-originating-ip: [113.29.88.7] x-clientproxiedby: HK2PR02CA0213.apcprd02.prod.outlook.com (2603:1096:201:20::25) To VE1PR08MB5006.eurprd08.prod.outlook.com (2603:10a6:803:113::31) x-ms-exchange-messagesentrepresentingtype: 1 x-mailer: git-send-email 2.17.1 x-ms-publictraffictype: Email x-ms-office365-filtering-correlation-id: dc0b18d2-eaec-4bd9-f286-08d6c878ef08 x-ms-office365-filtering-ht: Tenant x-microsoft-antispam: BCL:0; PCL:0; RULEID:(2390118)(7020095)(4652040)(8989299)(4534185)(7168020)(4627221)(201703031133081)(201702281549075)(8990200)(5600141)(711020)(4605104)(4618075)(2017052603328)(7193020); SRVR:VE1PR08MB5072; x-ms-traffictypediagnostic: VE1PR08MB5072: x-ms-exchange-purlcount: 1 nodisclaimer: True x-microsoft-antispam-prvs: x-forefront-prvs: 00179089FD x-forefront-antispam-report: SFV:NSPM; SFS:(10009020)(136003)(376002)(39860400002)(396003)(366004)(346002)(189003)(199004)(14444005)(1076003)(66946007)(26005)(14454004)(5660300002)(25786009)(71200400001)(71190400001)(52116002)(66446008)(64756008)(86362001)(966005)(486006)(66556008)(66476007)(2616005)(186003)(73956011)(476003)(97736004)(2501003)(2201001)(36756003)(102836004)(8936002)(99286004)(81166006)(3846002)(103116003)(81156014)(50226002)(6116002)(386003)(256004)(8676002)(2906002)(6436002)(4326008)(53936002)(305945005)(68736007)(6512007)(478600001)(6306002)(6486002)(54906003)(110136005)(316002)(55236004)(6506007)(66066001)(7736002); DIR:OUT; SFP:1101; SCL:1; SRVR:VE1PR08MB5072; H:VE1PR08MB5006.eurprd08.prod.outlook.com; FPR:; SPF:None; LANG:en; PTR:InfoNoRecords; MX:1; A:1; received-spf: None (protection.outlook.com: arm.com does not designate permitted sender hosts) x-ms-exchange-senderadcheck: 1 x-microsoft-antispam-message-info: VuxuBhAlFXUvmym2xPQddd0f7bTAXZg6WFjW0iJ0dRwDDW8ktXqzhN+AVrI9CiJGz9syRM8GuEzGYb820JSg3ZawucbJ84ghdUEKr3EEge8NbHpiXsoGXc499HHkI3xwZkRdlN//5q+gDKF/f1C/mjgUyGw2r498LujbDcK0d05P7ceFaZBoJDZEXEVWdFpakB0zt4q/fBCzkG6AFn7nhZtYe+EKv8YQs/F0EOAv/n72p3C8R7H1mxr7X1JXIql0nDddpVykKVtHigh2TFvGSVD39lZx4maJyQW+tpdF5xQeojH7d9tDbzXwo5600vofdl+88csC4YTEi1UHgy7cqsHALaSFmIUqUxzJJaXmf7/Kla1VQjXyvEdjubQKAgyeHhEK//LUw4yBCXwUPuNjk55a2clhvnZKeTEJw2FDgt0= MIME-Version: 1.0 X-OriginatorOrg: arm.com X-MS-Exchange-CrossTenant-Network-Message-Id: dc0b18d2-eaec-4bd9-f286-08d6c878ef08 X-MS-Exchange-CrossTenant-originalarrivaltime: 24 Apr 2019 05:51:45.5018 (UTC) X-MS-Exchange-CrossTenant-fromentityheader: Hosted X-MS-Exchange-CrossTenant-id: f34e5979-57d9-4aaa-ad4d-b122a662184d X-MS-Exchange-CrossTenant-mailboxtype: HOSTED X-MS-Exchange-Transport-CrossTenantHeadersStamped: VE1PR08MB5072 X-Mailman-Original-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=armh.onmicrosoft.com; s=selector1-arm-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=NyMnPcr6XyF21Z28ecs30tw7/PiqYoBk1XQPLGHX/qs=; b=Ca9w01daHqUTwIySKhTrjXHgNlLPRJLFol2RAJ90PxQyb/hPcadfIgvXZQy1hqhqGeIMBVW+1iVbgoRq5fw33PFf1dFDVJ28ZVL+5lyDnhbhU+eSW/4kv+OEMVc1YH9h9luvjQQsC5E9wFCzi8Ra3L6xqMRZ0njLSJTqUB5whJ0= X-Mailman-Original-Authentication-Results: spf=none (sender IP is ) smtp.mailfrom=james.qian.wang@arm.com; X-BeenThere: dri-devel@lists.freedesktop.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: Direct Rendering Infrastructure - Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: nd , Ayan Halder , "Tiannan Zhu \(Arm Technology China\)" , "Jonathan Chai \(Arm Technology China\)" , "linux-kernel@vger.kernel.org" , "dri-devel@lists.freedesktop.org" , "Julien Yin \(Arm Technology China\)" , "james qian wang \(Arm Technology China\)" , "Yiqi Kang \(Arm Technology China\)" , "thomas Sun \(Arm Technology China\)" , "Lowry Li \(Arm Technology China\)" Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" X-Virus-Scanned: ClamAV using ClamSMTP Fix the kbuild test rebot reported warnings: - symbol was not declared. Should it be static? - missing braces around initializer Depends on: - https://patchwork.freedesktop.org/series/58976/ Reported-by: kbuild test robot Signed-off-by: James (Qian) Wang Acked-by: Liviu Dudau --- .../gpu/drm/arm/display/komeda/d71/d71_component.c | 9 +++++---- drivers/gpu/drm/arm/display/komeda/komeda_crtc.c | 4 ++-- drivers/gpu/drm/arm/display/komeda/komeda_dev.c | 4 +++- drivers/gpu/drm/arm/display/komeda/komeda_drv.c | 2 +- drivers/gpu/drm/arm/display/komeda/komeda_pipeline.c | 2 +- .../drm/arm/display/komeda/komeda_pipeline_state.c | 11 ++++++----- drivers/gpu/drm/arm/display/komeda/komeda_plane.c | 10 ++++++---- 7 files changed, 24 insertions(+), 18 deletions(-) diff --git a/drivers/gpu/drm/arm/display/komeda/d71/d71_component.c b/drivers/gpu/drm/arm/display/komeda/d71/d71_component.c index c56cfc2de147..031e5f305a3c 100644 --- a/drivers/gpu/drm/arm/display/komeda/d71/d71_component.c +++ b/drivers/gpu/drm/arm/display/komeda/d71/d71_component.c @@ -391,7 +391,7 @@ static void d71_compiz_dump(struct komeda_component *c, struct seq_file *sf) seq_printf(sf, "CU_USER_HIGH:\t\t0x%X\n", v[1]); } -struct komeda_component_funcs d71_compiz_funcs = { +static struct komeda_component_funcs d71_compiz_funcs = { .update = d71_compiz_update, .disable = d71_component_disable, .dump_register = d71_compiz_dump, @@ -467,7 +467,7 @@ static void d71_improc_dump(struct komeda_component *c, struct seq_file *sf) seq_printf(sf, "IPS_RGB_YUV_COEFF%u:\t0x%X\n", i, v[i]); } -struct komeda_component_funcs d71_improc_funcs = { +static struct komeda_component_funcs d71_improc_funcs = { .update = d71_improc_update, .disable = d71_component_disable, .dump_register = d71_improc_dump, @@ -543,7 +543,8 @@ static void d71_timing_ctrlr_update(struct komeda_component *c, malidp_write32(reg, BLK_CONTROL, value); } -void d71_timing_ctrlr_dump(struct komeda_component *c, struct seq_file *sf) +static void d71_timing_ctrlr_dump(struct komeda_component *c, + struct seq_file *sf) { u32 v[8], i; @@ -579,7 +580,7 @@ void d71_timing_ctrlr_dump(struct komeda_component *c, struct seq_file *sf) seq_printf(sf, "BS_USER:\t\t0x%X\n", v[4]); } -struct komeda_component_funcs d71_timing_ctrlr_funcs = { +static struct komeda_component_funcs d71_timing_ctrlr_funcs = { .update = d71_timing_ctrlr_update, .disable = d71_timing_ctrlr_disable, .dump_register = d71_timing_ctrlr_dump, diff --git a/drivers/gpu/drm/arm/display/komeda/komeda_crtc.c b/drivers/gpu/drm/arm/display/komeda/komeda_crtc.c index d335fec1b727..62fad59f5a6a 100644 --- a/drivers/gpu/drm/arm/display/komeda/komeda_crtc.c +++ b/drivers/gpu/drm/arm/display/komeda/komeda_crtc.c @@ -52,7 +52,7 @@ komeda_crtc_atomic_check(struct drm_crtc *crtc, return 0; } -u32 komeda_calc_mclk(struct komeda_crtc_state *kcrtc_st) +static u32 komeda_calc_mclk(struct komeda_crtc_state *kcrtc_st) { unsigned long mclk = kcrtc_st->base.adjusted_mode.clock * 1000; @@ -350,7 +350,7 @@ static bool komeda_crtc_mode_fixup(struct drm_crtc *crtc, return true; } -struct drm_crtc_helper_funcs komeda_crtc_helper_funcs = { +static struct drm_crtc_helper_funcs komeda_crtc_helper_funcs = { .atomic_check = komeda_crtc_atomic_check, .atomic_flush = komeda_crtc_atomic_flush, .atomic_enable = komeda_crtc_atomic_enable, diff --git a/drivers/gpu/drm/arm/display/komeda/komeda_dev.c b/drivers/gpu/drm/arm/display/komeda/komeda_dev.c index 9d6c31cca875..2075f4ac7078 100644 --- a/drivers/gpu/drm/arm/display/komeda/komeda_dev.c +++ b/drivers/gpu/drm/arm/display/komeda/komeda_dev.c @@ -73,9 +73,11 @@ config_id_show(struct device *dev, struct device_attribute *attr, char *buf) { struct komeda_dev *mdev = dev_to_mdev(dev); struct komeda_pipeline *pipe = mdev->pipelines[0]; - union komeda_config_id config_id = {0,}; + union komeda_config_id config_id; int i; + config_id.value = 0; + config_id.max_line_sz = pipe->layers[0]->hsize_in.end; config_id.n_pipelines = mdev->n_pipelines; config_id.n_scalers = pipe->n_scalers; diff --git a/drivers/gpu/drm/arm/display/komeda/komeda_drv.c b/drivers/gpu/drm/arm/display/komeda/komeda_drv.c index 0285fd37a016..cfa5068d9d1e 100644 --- a/drivers/gpu/drm/arm/display/komeda/komeda_drv.c +++ b/drivers/gpu/drm/arm/display/komeda/komeda_drv.c @@ -127,7 +127,7 @@ static const struct komeda_product_data komeda_products[] = { }, }; -const struct of_device_id komeda_of_match[] = { +static const struct of_device_id komeda_of_match[] = { { .compatible = "arm,mali-d71", .data = &komeda_products[MALI_D71], }, {}, }; diff --git a/drivers/gpu/drm/arm/display/komeda/komeda_pipeline.c b/drivers/gpu/drm/arm/display/komeda/komeda_pipeline.c index 07398efc40f5..c379439c6194 100644 --- a/drivers/gpu/drm/arm/display/komeda/komeda_pipeline.c +++ b/drivers/gpu/drm/arm/display/komeda/komeda_pipeline.c @@ -62,7 +62,7 @@ void komeda_pipeline_destroy(struct komeda_dev *mdev, devm_kfree(mdev->dev, pipe); } -struct komeda_component ** +static struct komeda_component ** komeda_pipeline_get_component_pos(struct komeda_pipeline *pipe, int id) { struct komeda_dev *mdev = pipe->mdev; diff --git a/drivers/gpu/drm/arm/display/komeda/komeda_pipeline_state.c b/drivers/gpu/drm/arm/display/komeda/komeda_pipeline_state.c index ae1c3773c4ef..36570d7dad61 100644 --- a/drivers/gpu/drm/arm/display/komeda/komeda_pipeline_state.c +++ b/drivers/gpu/drm/arm/display/komeda/komeda_pipeline_state.c @@ -20,7 +20,7 @@ static inline bool is_switching_user(void *old, void *new) return old != new; } -struct komeda_pipeline_state * +static struct komeda_pipeline_state * komeda_pipeline_get_state(struct komeda_pipeline *pipe, struct drm_atomic_state *state) { @@ -45,7 +45,7 @@ komeda_pipeline_get_old_state(struct komeda_pipeline *pipe, return NULL; } -struct komeda_pipeline_state * +static struct komeda_pipeline_state * komeda_pipeline_get_new_state(struct komeda_pipeline *pipe, struct drm_atomic_state *state) { @@ -58,7 +58,7 @@ komeda_pipeline_get_new_state(struct komeda_pipeline *pipe, } /* Assign pipeline for crtc */ -struct komeda_pipeline_state * +static struct komeda_pipeline_state * komeda_pipeline_get_state_and_set_crtc(struct komeda_pipeline *pipe, struct drm_atomic_state *state, struct drm_crtc *crtc) @@ -505,8 +505,9 @@ int komeda_build_display_data_flow(struct komeda_crtc *kcrtc, return 0; } -void komeda_pipeline_unbound_components(struct komeda_pipeline *pipe, - struct komeda_pipeline_state *new) +static void +komeda_pipeline_unbound_components(struct komeda_pipeline *pipe, + struct komeda_pipeline_state *new) { struct drm_atomic_state *drm_st = new->obj.state; struct komeda_pipeline_state *old = priv_to_pipe_st(pipe->obj.state); diff --git a/drivers/gpu/drm/arm/display/komeda/komeda_plane.c b/drivers/gpu/drm/arm/display/komeda/komeda_plane.c index 46654f0be73d..07ed0cc1bc44 100644 --- a/drivers/gpu/drm/arm/display/komeda/komeda_plane.c +++ b/drivers/gpu/drm/arm/display/komeda/komeda_plane.c @@ -47,8 +47,9 @@ komeda_plane_init_data_flow(struct drm_plane_state *st, * RETURNS: * Zero for success or -errno */ -int komeda_plane_atomic_check(struct drm_plane *plane, - struct drm_plane_state *state) +static int +komeda_plane_atomic_check(struct drm_plane *plane, + struct drm_plane_state *state) { struct komeda_plane *kplane = to_kplane(plane); struct komeda_plane_state *kplane_st = to_kplane_st(state); @@ -87,8 +88,9 @@ int komeda_plane_atomic_check(struct drm_plane *plane, /* plane doesn't represent a real HW, so there is no HW update for plane. * komeda handles all the HW update in crtc->atomic_flush */ -void komeda_plane_atomic_update(struct drm_plane *plane, - struct drm_plane_state *old_state) +static void +komeda_plane_atomic_update(struct drm_plane *plane, + struct drm_plane_state *old_state) { }