Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1701290

[PATCH 04/18] [media] meye: constify pci_device_id.

Path csiph.com!news.mixmin.net!aioe.org!bofh.it!news.nic.it!robomod
From Arvind Yadav <arvind.yadav.cs@gmail.com>
Newsgroups linux.kernel
Subject [PATCH 04/18] [media] meye: constify pci_device_id.
Date Tue, 01 Aug 2017 20:00:02 +0200
Message-ID <u9JCy-74V-29@gated-at.bofh.it> (permalink)
References <u9JCx-74V-3@gated-at.bofh.it>
Dkim-Signature v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=zvFpkAW4bwTojGPTKIl9AH+2WlNZSNIHEkvW0Lu6Ybs=; b=oCHi4j10VvLbVUTp5W+LG/rdXqk/1FpRoHH2ZDCJ1layqCxiQoJ7Frgek4YZGLhdho s5hoN8BbEzbXnUMsZkh1RCS5UvfLlcVlXe60H0vX3bwX49jvR9icE5bbVucIKeyF5yvu datLdgYvmbAo5SL5gej/G1O9c27VPXEWx/L34CnVz9rt8FnKZH7OxeKhrsunXvXW4xLC khcRbqhvJrE5/r2uYeGnA/7Bl5Xt7t0HUhdmmesvy99LGA1enHsC17vVsUDya0XnTASD yBvlRDseT94Z1PToM8q7eJFZbHMKxl1xxlHCNBMO/btKDJD4gk3UIHWjLWXcRC4T6rj/ 8LsA==
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; bh=zvFpkAW4bwTojGPTKIl9AH+2WlNZSNIHEkvW0Lu6Ybs=; b=QOkt3fjrS1tY5uDXqOGUat4JdiWoVosKGnhOYWBe6grKPNA29i/JZnN6jBSiTisvy2 SkFErnVx4u1LTuAv3xZ/UF3+B7RTx8ZSb9HljG32tqKwywfZs//Zgv9jMca5Poy0eF1d z4tBXFWQcdiOHhMjWNgLDFWlB/fe+HpMZ3NlvTQdIwbjT1F7JidHUXNkP//D3i2jGS96 4Ox4mLvs/uS+PmELY6L2E8HIgcZ3NSTQWZnAlzIQY4cEMW6aS4Ytw4satNdJSt8xZj8e VdoSZJ2IRVMvtlIK7arDTp1HsdOsa7mttjIXQWWtg8jInxV8RmRC/QL7XHEDKL8PAL4u Hqtw==
X-Gm-Message-State AIVw113Jng9tQdoZ0iItH65VE1A3xQIh+tdQcqfpWQRaqmEw1LiB2jvd Vxhjd3TfYtTJwQ==
X-Received by 10.98.68.218 with SMTP id m87mr19573288pfi.16.1501610250317; Tue, 01 Aug 2017 10:57:30 -0700 (PDT)
X-Mailer git-send-email 2.7.4
Sender robomod@news.nic.it
List-ID <linux-kernel.vger.kernel.org>
X-Mailing-List linux-kernel@vger.kernel.org
Approved robomod@news.nic.it
Lines 24
Organization linux.* mail to news gateway
X-Original-Cc linux-media@vger.kernel.org, linux-kernel@vger.kernel.org
X-Original-Date Tue, 1 Aug 2017 23:26:20 +0530
X-Original-Message-ID <1501610194-8231-5-git-send-email-arvind.yadav.cs@gmail.com>
X-Original-References <1501610194-8231-1-git-send-email-arvind.yadav.cs@gmail.com>
X-Original-Sender linux-kernel-owner@vger.kernel.org
Xref csiph.com linux.kernel:1701290

Show key headers only | View raw


pci_device_id are not supposed to change at runtime. All functions
working with pci_device_id provided by <linux/pci.h> work with
const pci_device_id. So mark the non-const structs as const.

Signed-off-by: Arvind Yadav <arvind.yadav.cs@gmail.com>
---
 drivers/media/pci/meye/meye.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/media/pci/meye/meye.c b/drivers/media/pci/meye/meye.c
index 9c4a024..0fe76be 100644
--- a/drivers/media/pci/meye/meye.c
+++ b/drivers/media/pci/meye/meye.c
@@ -1801,7 +1801,7 @@ static void meye_remove(struct pci_dev *pcidev)
 	printk(KERN_INFO "meye: removed\n");
 }
 
-static struct pci_device_id meye_pci_tbl[] = {
+static const struct pci_device_id meye_pci_tbl[] = {
 	{ PCI_VDEVICE(KAWASAKI, PCI_DEVICE_ID_MCHIP_KL5A72002), 0 },
 	{ }
 };
-- 
2.7.4

Back to linux.kernel | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread


Thread

[PATCH 00/18] constify media pci_device_id Arvind Yadav <arvind.yadav.cs@gmail.com> - 2017-08-01 20:00 +0200
  [PATCH 15/18] [media] mantis: constify pci_device_id. Arvind Yadav <arvind.yadav.cs@gmail.com> - 2017-08-01 20:00 +0200
  [PATCH 03/18] [media] cx23885: constify pci_device_id. Arvind Yadav <arvind.yadav.cs@gmail.com> - 2017-08-01 20:00 +0200
  [PATCH 06/18] [media] dm1105: constify pci_device_id. Arvind Yadav <arvind.yadav.cs@gmail.com> - 2017-08-01 20:00 +0200
  [PATCH 14/18] [media] pt1: constify pci_device_id. Arvind Yadav <arvind.yadav.cs@gmail.com> - 2017-08-01 20:00 +0200
  [PATCH 04/18] [media] meye: constify pci_device_id. Arvind Yadav <arvind.yadav.cs@gmail.com> - 2017-08-01 20:00 +0200
  [PATCH 16/18] [media] mantis: hopper_cards: constify pci_device_id. Arvind Yadav <arvind.yadav.cs@gmail.com> - 2017-08-01 20:00 +0200
  [PATCH 13/18] [media] saa7164: constify pci_device_id. Arvind Yadav <arvind.yadav.cs@gmail.com> - 2017-08-01 20:00 +0200
  [PATCH 18/18] [media] radio: constify pci_device_id. Arvind Yadav <arvind.yadav.cs@gmail.com> - 2017-08-01 20:00 +0200
  [PATCH 09/18] [media] bt8xx: bttv: constify pci_device_id. Arvind Yadav <arvind.yadav.cs@gmail.com> - 2017-08-01 20:10 +0200
  [PATCH 05/18] [media] pluto2: constify pci_device_id. Arvind Yadav <arvind.yadav.cs@gmail.com> - 2017-08-01 20:10 +0200
  [PATCH 11/18] [media] cobalt: constify pci_device_id. Arvind Yadav <arvind.yadav.cs@gmail.com> - 2017-08-01 20:10 +0200
  [PATCH 12/18] [media] b2c2: constify pci_device_id. Arvind Yadav <arvind.yadav.cs@gmail.com> - 2017-08-01 20:10 +0200
  [PATCH 07/18] [media] zoran: constify pci_device_id. Arvind Yadav <arvind.yadav.cs@gmail.com> - 2017-08-01 20:10 +0200
  [PATCH 02/18] [media] netup_unidvb: constify pci_device_id. Arvind Yadav <arvind.yadav.cs@gmail.com> - 2017-08-01 20:10 +0200

csiph-web