From patchwork Sun Nov 8 22:37:38 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Rikard Falkeborn X-Patchwork-Id: 11890021 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=-12.3 required=3.0 tests=BAYES_00, DKIM_ADSP_CUSTOM_MED,DKIM_INVALID,DKIM_SIGNED,FREEMAIL_FORGED_FROMDOMAIN, FREEMAIL_FROM,HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_PATCH,MAILING_LIST_MULTI, SIGNED_OFF_BY,SPF_HELO_NONE,SPF_PASS,USER_AGENT_GIT autolearn=ham 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 DFB40C388F9 for ; Sun, 8 Nov 2020 22:50:21 +0000 (UTC) Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 884F1206DB for ; Sun, 8 Nov 2020 22:50:21 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=fail reason="signature verification failed" (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b="MvhNV0Y5" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 884F1206DB Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=gmail.com Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=dri-devel-bounces@lists.freedesktop.org Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 2793F89811; Sun, 8 Nov 2020 22:49:39 +0000 (UTC) Received: from mail-lf1-x143.google.com (mail-lf1-x143.google.com [IPv6:2a00:1450:4864:20::143]) by gabe.freedesktop.org (Postfix) with ESMTPS id 1458089728; Sun, 8 Nov 2020 22:37:45 +0000 (UTC) Received: by mail-lf1-x143.google.com with SMTP id s30so9713435lfc.4; Sun, 08 Nov 2020 14:37:44 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=kCfJ2Jg/FRbU0HYZuU5nyJHXfw9uLTxJyOfF7KFa57E=; b=MvhNV0Y5I33YbxT2Ln2NrfmREwh8lPFZ+3xU2EFtr2CAsZKR+wM35afUYsQBmrKDQk LYt8VUWG/y9jOYIUakzX7JTDIaX0ID95B4xc+8Ye9cJHF/5lJPlPg8B9LCCYP/OCfpw4 OXeIBOX8so5xs5BNF5WC1D6ZOdQcB/uhGrxHX3YXOXQMd0q4POzkdj6MeckEc2C8s9Lt ABnP2NIYf/9rKSSc9j/z8TcKsy0VtvKkG7w11jm0L5QYWQH/Y1VmRsNGpHGPbs+jQkoG SyioOkj3E9EykvgsnwUDawY0P7JWEqRneiWIVhpVMAFYyJjq3FsGWSMCt664MsVeFgMV b7Qw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=kCfJ2Jg/FRbU0HYZuU5nyJHXfw9uLTxJyOfF7KFa57E=; b=aNBPM2FdrpsfouBf4BPnoC+fS+QCfBwX/ZrULYiAcA8KD0NO2SqBldxMOo2oGnz2vz UXtLL18fWTs4QVYG4LEpptMLOzeJGF9aqN8M49fUjZnYAVdWnptPX3JDYoYBFSaINLT5 tbyqw1Ov0ZxJBxwTrXWoEUHSEOMK1iSsqD3NPgbdzz9CGAMl2j8yizEfbV6G/co0FdVz IpSfso4ZX8EppJooGwKWtRhgUTv+I4k0cJ74LW7EHOBKUdsSS6ts+giW16xf28dCXhrV tO+z+SZwVdkhzZV2coFBZnhgvpWFacyQZrKHkrDYykLCQ6+Zw9KAJWZmFQYmiU024bmC HrOg== X-Gm-Message-State: AOAM530wAG5sasvlwKWy7AsGfMCxXQcdC5Z8XBoWbBsiZZKK+JUPfTHV BwfAGAjKKQZkeH4All065uI= X-Google-Smtp-Source: ABdhPJzuO6s0AWBQsGZ7IxbiJF3RrVQVDq0L03EJ0cQaiYYgIRSJQ5uljgZfXN2ou61c+TYUsgGFmQ== X-Received: by 2002:a19:4050:: with SMTP id n77mr4313723lfa.460.1604875063419; Sun, 08 Nov 2020 14:37:43 -0800 (PST) Received: from localhost.localdomain (h-155-4-221-112.NA.cust.bahnhof.se. [155.4.221.112]) by smtp.gmail.com with ESMTPSA id b25sm1559932lff.48.2020.11.08.14.37.42 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 08 Nov 2020 14:37:42 -0800 (PST) From: Rikard Falkeborn To: Rob Clark , Sean Paul , David Airlie , Daniel Vetter Subject: [PATCH] drm/msm: dsi: Constify dsi_host_ops Date: Sun, 8 Nov 2020 23:37:38 +0100 Message-Id: <20201108223738.16535-1-rikard.falkeborn@gmail.com> X-Mailer: git-send-email 2.29.2 MIME-Version: 1.0 X-Mailman-Approved-At: Sun, 08 Nov 2020 22:49:24 +0000 X-BeenThere: dri-devel@lists.freedesktop.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Direct Rendering Infrastructure - Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Rikard Falkeborn , linux-arm-msm@vger.kernel.org, freedreno@lists.freedesktop.org, linux-kernel@vger.kernel.org, dri-devel@lists.freedesktop.org Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" The only usage of dsi_host_ops is to assign its address to the ops field in the mipi_dsi_host struct, which is a const pointer. Make it const to allow the compiler to put it in read-only memory. Signed-off-by: Rikard Falkeborn Reviewed-by: Sam Ravnborg --- drivers/gpu/drm/msm/dsi/dsi_host.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/gpu/drm/msm/dsi/dsi_host.c b/drivers/gpu/drm/msm/dsi/dsi_host.c index 198db8d4cf3d..ab281cba0f08 100644 --- a/drivers/gpu/drm/msm/dsi/dsi_host.c +++ b/drivers/gpu/drm/msm/dsi/dsi_host.c @@ -1657,7 +1657,7 @@ static ssize_t dsi_host_transfer(struct mipi_dsi_host *host, return ret; } -static struct mipi_dsi_host_ops dsi_host_ops = { +static const struct mipi_dsi_host_ops dsi_host_ops = { .attach = dsi_host_attach, .detach = dsi_host_detach, .transfer = dsi_host_transfer,