From patchwork Wed Dec 19 19:22:46 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Emil Velikov X-Patchwork-Id: 10738035 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 A49516C2 for ; Wed, 19 Dec 2018 19:25:48 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 9437027D29 for ; Wed, 19 Dec 2018 19:25:48 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 88CC927E5A; Wed, 19 Dec 2018 19:25:48 +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,DKIM_ADSP_CUSTOM_MED, FREEMAIL_FROM,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 568CD27D29 for ; Wed, 19 Dec 2018 19:25:48 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 6366B6F16B; Wed, 19 Dec 2018 19:25:47 +0000 (UTC) X-Original-To: dri-devel@lists.freedesktop.org Delivered-To: dri-devel@lists.freedesktop.org Received: from mail-wm1-x342.google.com (mail-wm1-x342.google.com [IPv6:2a00:1450:4864:20::342]) by gabe.freedesktop.org (Postfix) with ESMTPS id 29EF56F169 for ; Wed, 19 Dec 2018 19:25:37 +0000 (UTC) Received: by mail-wm1-x342.google.com with SMTP id y139so7144323wmc.5 for ; Wed, 19 Dec 2018 11:25:37 -0800 (PST) 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:in-reply-to :references:mime-version:content-transfer-encoding; bh=g0ayEe9XWPHXZB+3M5JX2isJD4dEF8GcxOpp3w3z0FI=; b=ZKrKxHtPbrgo6x4XZU8TJgqgmDisY5LAuydi1YT+ganUB6E3TXb8z68bA1f1VWct1Y LIgZVENfyPsHuOkOqQow+5OkwUNcw7gKcXtDJ6Zc5Y6ECjHYbriK/fvEcfPyckXh8g+d ITL68C4a51S0USUjEsAVgMBi8n3Sb7UJMlaGoSFHC/Sc+YBTaDpybtoUzzUS4JI6Q2vj +ngqrZt0M0Bvmlir2Tzq4SkixQgkmDy8tuCSplfkC9FyAKhwE4cp2z2dIRZMBEG/jP0N ctl2xGo7IPFGH8ZKBPrM4kUtYsuWZucH4cFNAxve6+C9pS6oaEpgg+aXElU6+J2ioGzm pXdA== X-Gm-Message-State: AA+aEWaoUn1awbel2zTW86b5LUqk/UAQIR/rfPLSkvmePLvNWLARMS7H 9kpQYGj9aV3VQum/m2WRdqG3BFBCP0c= X-Google-Smtp-Source: AFSGD/Xv938bdS7of3xFJ7Yzj1+4sg5ACfgPqDrEtSTt0lHaOsN7iPQ1hexSp4ubXrwLBQTWyJ4X3w== X-Received: by 2002:a1c:2e43:: with SMTP id u64mr8594587wmu.52.1545247535523; Wed, 19 Dec 2018 11:25:35 -0800 (PST) Received: from arch-x1c3.cbg.collabora.co.uk ([2a00:5f00:102:0:9665:9cff:feee:aa4d]) by smtp.gmail.com with ESMTPSA id c9sm7385483wmh.27.2018.12.19.11.25.34 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Wed, 19 Dec 2018 11:25:34 -0800 (PST) From: Emil Velikov To: dri-devel@lists.freedesktop.org Subject: [PATCH 2/3] drm: annotate drm_core_check_feature() dev arg. as const Date: Wed, 19 Dec 2018 19:22:46 +0000 Message-Id: <20181219192247.29880-3-emil.l.velikov@gmail.com> X-Mailer: git-send-email 2.19.2 In-Reply-To: <20181219192247.29880-1-emil.l.velikov@gmail.com> References: <20181219192247.29880-1-emil.l.velikov@gmail.com> MIME-Version: 1.0 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: emil.l.velikov@gmail.com Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" X-Virus-Scanned: ClamAV using ClamSMTP From: Emil Velikov This static inline function doesn't modify any state. Signed-off-by: Emil Velikov Reviewed-by: Daniel Vetter --- include/drm/drm_drv.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/include/drm/drm_drv.h b/include/drm/drm_drv.h index 35af23f5fa0d..eca73330ffaf 100644 --- a/include/drm/drm_drv.h +++ b/include/drm/drm_drv.h @@ -666,7 +666,7 @@ static inline bool drm_dev_is_unplugged(struct drm_device *dev) * * Returns true if the @feature is supported, false otherwise. */ -static inline bool drm_core_check_feature(struct drm_device *dev, u32 feature) +static inline bool drm_core_check_feature(const struct drm_device *dev, u32 feature) { return dev->driver->driver_features & dev->driver_features & feature; }