aboutsummaryrefslogtreecommitdiffstats
path: root/arch/arm/mach-omap1
diff options
context:
space:
mode:
authorTony Lindgren <tony@atomide.com>2021-01-15 12:48:43 +0200
committerTony Lindgren <tony@atomide.com>2021-01-15 12:48:43 +0200
commit715a1284d89a740b197b3bad5eb20d36a397382f (patch)
tree07ad2960ab66e56b3d1e151036262019a18e3df1 /arch/arm/mach-omap1
parentARM: dts; gta04: SPI panel chip select is active low (diff)
parentARM: OMAP2+: Fix suspcious RCU usage splats for omap_enter_idle_coupled (diff)
downloadlinux-dev-715a1284d89a740b197b3bad5eb20d36a397382f.tar.xz
linux-dev-715a1284d89a740b197b3bad5eb20d36a397382f.zip
Merge branch 'cpuidle-fix' into fixes
Diffstat (limited to 'arch/arm/mach-omap1')
-rw-r--r--arch/arm/mach-omap1/board-h2.c22
-rw-r--r--arch/arm/mach-omap1/clock.c14
-rw-r--r--arch/arm/mach-omap1/usb.c2
3 files changed, 28 insertions, 10 deletions
diff --git a/arch/arm/mach-omap1/board-h2.c b/arch/arm/mach-omap1/board-h2.c
index cb7ce627ffe8..c40cf5ef8607 100644
--- a/arch/arm/mach-omap1/board-h2.c
+++ b/arch/arm/mach-omap1/board-h2.c
@@ -16,6 +16,7 @@
* Copyright (C) 2004 Nokia Corporation by Imre Deak <imre.deak@nokia.com>
*/
#include <linux/gpio.h>
+#include <linux/gpio/machine.h>
#include <linux/kernel.h>
#include <linux/platform_device.h>
#include <linux/delay.h>
@@ -46,6 +47,9 @@
#include "common.h"
#include "board-h2.h"
+/* The first 16 SoC GPIO lines are on this GPIO chip */
+#define OMAP_GPIO_LABEL "gpio-0-15"
+
/* At OMAP1610 Innovator the Ethernet is directly connected to CS1 */
#define OMAP1610_ETHR_START 0x04000300
@@ -334,7 +338,19 @@ static struct i2c_board_info __initdata h2_i2c_board_info[] = {
I2C_BOARD_INFO("tps65010", 0x48),
.platform_data = &tps_board,
}, {
- I2C_BOARD_INFO("isp1301_omap", 0x2d),
+ .type = "isp1301_omap",
+ .addr = 0x2d,
+ .dev_name = "isp1301",
+ },
+};
+
+static struct gpiod_lookup_table isp1301_gpiod_table = {
+ .dev_id = "isp1301",
+ .table = {
+ /* Active low since the irq triggers on falling edge */
+ GPIO_LOOKUP(OMAP_GPIO_LABEL, 2,
+ NULL, GPIO_ACTIVE_LOW),
+ { },
},
};
@@ -406,8 +422,10 @@ static void __init h2_init(void)
h2_smc91x_resources[1].end = gpio_to_irq(0);
platform_add_devices(h2_devices, ARRAY_SIZE(h2_devices));
omap_serial_init();
+
+ /* ISP1301 IRQ wired at M14 */
+ omap_cfg_reg(M14_1510_GPIO2);
h2_i2c_board_info[0].irq = gpio_to_irq(58);
- h2_i2c_board_info[1].irq = gpio_to_irq(2);
omap_register_i2c_bus(1, 100, h2_i2c_board_info,
ARRAY_SIZE(h2_i2c_board_info));
omap1_usb_init(&h2_usb_config);
diff --git a/arch/arm/mach-omap1/clock.c b/arch/arm/mach-omap1/clock.c
index bd5be82101f3..9d4a0ab50a46 100644
--- a/arch/arm/mach-omap1/clock.c
+++ b/arch/arm/mach-omap1/clock.c
@@ -612,7 +612,7 @@ int clk_enable(struct clk *clk)
unsigned long flags;
int ret;
- if (clk == NULL || IS_ERR(clk))
+ if (IS_ERR_OR_NULL(clk))
return -EINVAL;
spin_lock_irqsave(&clockfw_lock, flags);
@@ -627,7 +627,7 @@ void clk_disable(struct clk *clk)
{
unsigned long flags;
- if (clk == NULL || IS_ERR(clk))
+ if (IS_ERR_OR_NULL(clk))
return;
spin_lock_irqsave(&clockfw_lock, flags);
@@ -650,7 +650,7 @@ unsigned long clk_get_rate(struct clk *clk)
unsigned long flags;
unsigned long ret;
- if (clk == NULL || IS_ERR(clk))
+ if (IS_ERR_OR_NULL(clk))
return 0;
spin_lock_irqsave(&clockfw_lock, flags);
@@ -670,7 +670,7 @@ long clk_round_rate(struct clk *clk, unsigned long rate)
unsigned long flags;
long ret;
- if (clk == NULL || IS_ERR(clk))
+ if (IS_ERR_OR_NULL(clk))
return 0;
spin_lock_irqsave(&clockfw_lock, flags);
@@ -686,7 +686,7 @@ int clk_set_rate(struct clk *clk, unsigned long rate)
unsigned long flags;
int ret = -EINVAL;
- if (clk == NULL || IS_ERR(clk))
+ if (IS_ERR_OR_NULL(clk))
return ret;
spin_lock_irqsave(&clockfw_lock, flags);
@@ -791,7 +791,7 @@ void clk_preinit(struct clk *clk)
int clk_register(struct clk *clk)
{
- if (clk == NULL || IS_ERR(clk))
+ if (IS_ERR_OR_NULL(clk))
return -EINVAL;
/*
@@ -817,7 +817,7 @@ EXPORT_SYMBOL(clk_register);
void clk_unregister(struct clk *clk)
{
- if (clk == NULL || IS_ERR(clk))
+ if (IS_ERR_OR_NULL(clk))
return;
mutex_lock(&clocks_mutex);
diff --git a/arch/arm/mach-omap1/usb.c b/arch/arm/mach-omap1/usb.c
index ba8566204ea9..86d3b3c157af 100644
--- a/arch/arm/mach-omap1/usb.c
+++ b/arch/arm/mach-omap1/usb.c
@@ -9,7 +9,7 @@
#include <linux/kernel.h>
#include <linux/init.h>
#include <linux/platform_device.h>
-#include <linux/dma-mapping.h>
+#include <linux/dma-map-ops.h>
#include <linux/io.h>
#include <asm/irq.h>