PCI: qcom: Account for const type of of_device_id.data
authorJulia Lawall <Julia.Lawall@lip6.fr>
Tue, 2 Jan 2018 13:28:00 +0000 (14:28 +0100)
committerLorenzo Pieralisi <lorenzo.pieralisi@arm.com>
Wed, 3 Jan 2018 18:16:08 +0000 (18:16 +0000)
commit8e64a7cce7b16e02e00eeb16f66909022b200da6
tree88e9610e01690f09ce6754a72d7310685b81bbd6
parentc68febfd68e0f01d90da15bd10e94b42544f0f68
PCI: qcom: Account for const type of of_device_id.data

This driver creates various const structures that it stores in the
data field of an of_device_id array.

Adding const to the declaration of the location that receives the
const value from the data field ensures that the compiler will
continue to check that the value is not modified.  Furthermore, the
const-discarding cast on the extraction from the data field is no
longer needed.

Done using Coccinelle.

Signed-off-by: Julia Lawall <Julia.Lawall@lip6.fr>
Signed-off-by: Lorenzo Pieralisi <lorenzo.pieralisi@arm.com>
Acked-by: Stanimir Varbanov <svarbanov@mm-sol.com>
drivers/pci/dwc/pcie-qcom.c