tty: constify of_device_id array
of_device_id is always used as const. (See driver.of_match_table and open firmware functions) Signed-off-by: Fabian Frederick <fabf@skynet.be> Acked-by: Peter Korsgaard <peter@korsgaard.com> Acked-by: Timur Tabi <timur@tabi.org> Acked-by: Patrice Chotard <patrice.chotard@st.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This commit is contained in:
parent
37ff5252b3
commit
ed0bb2323c
@ -572,7 +572,7 @@ static int apbuart_probe(struct platform_device *op)
|
||||
return 0;
|
||||
}
|
||||
|
||||
static struct of_device_id apbuart_match[] = {
|
||||
static const struct of_device_id apbuart_match[] = {
|
||||
{
|
||||
.name = "GAISLER_APBUART",
|
||||
},
|
||||
|
@ -1435,7 +1435,7 @@ static int cpm_uart_remove(struct platform_device *ofdev)
|
||||
return uart_remove_one_port(&cpm_reg, &pinfo->port);
|
||||
}
|
||||
|
||||
static struct of_device_id cpm_uart_match[] = {
|
||||
static const struct of_device_id cpm_uart_match[] = {
|
||||
{
|
||||
.compatible = "fsl,cpm1-smc-uart",
|
||||
},
|
||||
|
@ -257,7 +257,7 @@ struct lpuart_port {
|
||||
struct timer_list lpuart_timer;
|
||||
};
|
||||
|
||||
static struct of_device_id lpuart_dt_ids[] = {
|
||||
static const struct of_device_id lpuart_dt_ids[] = {
|
||||
{
|
||||
.compatible = "fsl,vf610-lpuart",
|
||||
},
|
||||
|
@ -1717,7 +1717,7 @@ static struct uart_driver mpc52xx_uart_driver = {
|
||||
/* OF Platform Driver */
|
||||
/* ======================================================================== */
|
||||
|
||||
static struct of_device_id mpc52xx_uart_of_match[] = {
|
||||
static const struct of_device_id mpc52xx_uart_of_match[] = {
|
||||
#ifdef CONFIG_PPC_MPC52xx
|
||||
{ .compatible = "fsl,mpc5200b-psc-uart", .data = &mpc5200b_psc_ops, },
|
||||
{ .compatible = "fsl,mpc5200-psc-uart", .data = &mpc52xx_psc_ops, },
|
||||
|
@ -176,7 +176,7 @@ static struct platform_device_id mxs_auart_devtype[] = {
|
||||
};
|
||||
MODULE_DEVICE_TABLE(platform, mxs_auart_devtype);
|
||||
|
||||
static struct of_device_id mxs_auart_dt_ids[] = {
|
||||
static const struct of_device_id mxs_auart_dt_ids[] = {
|
||||
{
|
||||
.compatible = "fsl,imx28-auart",
|
||||
.data = &mxs_auart_devtype[IMX28_AUART]
|
||||
|
@ -155,7 +155,7 @@ out:
|
||||
/*
|
||||
* Try to register a serial port
|
||||
*/
|
||||
static struct of_device_id of_platform_serial_table[];
|
||||
static const struct of_device_id of_platform_serial_table[];
|
||||
static int of_platform_serial_probe(struct platform_device *ofdev)
|
||||
{
|
||||
const struct of_device_id *match;
|
||||
@ -320,7 +320,7 @@ static SIMPLE_DEV_PM_OPS(of_serial_pm_ops, of_serial_suspend, of_serial_resume);
|
||||
/*
|
||||
* A few common types, add more as needed.
|
||||
*/
|
||||
static struct of_device_id of_platform_serial_table[] = {
|
||||
static const struct of_device_id of_platform_serial_table[] = {
|
||||
{ .compatible = "ns8250", .data = (void *)PORT_8250, },
|
||||
{ .compatible = "ns16450", .data = (void *)PORT_16450, },
|
||||
{ .compatible = "ns16550a", .data = (void *)PORT_16550A, },
|
||||
|
@ -1846,7 +1846,7 @@ static int __init pmz_register(void)
|
||||
|
||||
#ifdef CONFIG_PPC_PMAC
|
||||
|
||||
static struct of_device_id pmz_match[] =
|
||||
static const struct of_device_id pmz_match[] =
|
||||
{
|
||||
{
|
||||
.name = "ch-a",
|
||||
|
@ -824,7 +824,7 @@ static const struct dev_pm_ops serial_pxa_pm_ops = {
|
||||
};
|
||||
#endif
|
||||
|
||||
static struct of_device_id serial_pxa_dt_ids[] = {
|
||||
static const struct of_device_id serial_pxa_dt_ids[] = {
|
||||
{ .compatible = "mrvl,pxa-uart", },
|
||||
{ .compatible = "mrvl,mmp-uart", },
|
||||
{}
|
||||
|
@ -1251,7 +1251,7 @@ static struct tegra_uart_chip_data tegra30_uart_chip_data = {
|
||||
.support_clk_src_div = true,
|
||||
};
|
||||
|
||||
static struct of_device_id tegra_uart_of_match[] = {
|
||||
static const struct of_device_id tegra_uart_of_match[] = {
|
||||
{
|
||||
.compatible = "nvidia,tegra30-hsuart",
|
||||
.data = &tegra30_uart_chip_data,
|
||||
|
@ -1269,7 +1269,7 @@ static struct uart_driver sirfsoc_uart_drv = {
|
||||
#endif
|
||||
};
|
||||
|
||||
static struct of_device_id sirfsoc_uart_ids[] = {
|
||||
static const struct of_device_id sirfsoc_uart_ids[] = {
|
||||
{ .compatible = "sirf,prima2-uart", .data = &sirfsoc_uart,},
|
||||
{ .compatible = "sirf,atlas7-uart", .data = &sirfsoc_uart},
|
||||
{ .compatible = "sirf,prima2-usp-uart", .data = &sirfsoc_usp},
|
||||
|
@ -720,7 +720,7 @@ static struct asc_port *asc_of_get_asc_port(struct platform_device *pdev)
|
||||
}
|
||||
|
||||
#ifdef CONFIG_OF
|
||||
static struct of_device_id asc_match[] = {
|
||||
static const struct of_device_id asc_match[] = {
|
||||
{ .compatible = "st,asc", },
|
||||
{},
|
||||
};
|
||||
|
@ -622,7 +622,7 @@ static int ulite_release(struct device *dev)
|
||||
|
||||
#if defined(CONFIG_OF)
|
||||
/* Match table for of_platform binding */
|
||||
static struct of_device_id ulite_of_match[] = {
|
||||
static const struct of_device_id ulite_of_match[] = {
|
||||
{ .compatible = "xlnx,opb-uartlite-1.00.b", },
|
||||
{ .compatible = "xlnx,xps-uartlite-1.00.a", },
|
||||
{}
|
||||
|
@ -1473,7 +1473,7 @@ static int ucc_uart_remove(struct platform_device *ofdev)
|
||||
return 0;
|
||||
}
|
||||
|
||||
static struct of_device_id ucc_uart_match[] = {
|
||||
static const struct of_device_id ucc_uart_match[] = {
|
||||
{
|
||||
.type = "serial",
|
||||
.compatible = "ucc_uart",
|
||||
|
@ -1459,7 +1459,7 @@ static int cdns_uart_remove(struct platform_device *pdev)
|
||||
}
|
||||
|
||||
/* Match table for of_platform binding */
|
||||
static struct of_device_id cdns_uart_of_match[] = {
|
||||
static const struct of_device_id cdns_uart_of_match[] = {
|
||||
{ .compatible = "xlnx,xuartps", },
|
||||
{ .compatible = "cdns,uart-r1p8", },
|
||||
{}
|
||||
|
Loading…
Reference in New Issue
Block a user