瀏覽代碼

net: ibm: ibmvnic: constify vio_device_id

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

Signed-off-by: Arvind Yadav <arvind.yadav.cs@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Arvind Yadav 8 年之前
父節點
當前提交
8c37bc677a
共有 1 個文件被更改,包括 1 次插入1 次删除
  1. 1 1
      drivers/net/ethernet/ibm/ibmvnic.c

+ 1 - 1
drivers/net/ethernet/ibm/ibmvnic.c

@@ -4022,7 +4022,7 @@ static int ibmvnic_resume(struct device *dev)
 	return 0;
 }
 
-static struct vio_device_id ibmvnic_device_table[] = {
+static const struct vio_device_id ibmvnic_device_table[] = {
 	{"network", "IBM,vnic"},
 	{"", "" }
 };