diff options
Diffstat (limited to 'include/linux')
| -rw-r--r-- | include/linux/hardirq.h | 8 | ||||
| -rw-r--r-- | include/linux/mmc/sh_mmcif.h | 18 | ||||
| -rw-r--r-- | include/linux/sh_clk.h | 4 | ||||
| -rw-r--r-- | include/linux/sh_timer.h | 1 |
4 files changed, 19 insertions, 12 deletions
diff --git a/include/linux/hardirq.h b/include/linux/hardirq.h index 8a389b608ce3..41cb31f14ee3 100644 --- a/include/linux/hardirq.h +++ b/include/linux/hardirq.h | |||
| @@ -96,11 +96,15 @@ | |||
| 96 | */ | 96 | */ |
| 97 | #define in_nmi() (preempt_count() & NMI_MASK) | 97 | #define in_nmi() (preempt_count() & NMI_MASK) |
| 98 | 98 | ||
| 99 | #if defined(CONFIG_PREEMPT) | 99 | #if defined(CONFIG_PREEMPT) && defined(CONFIG_BKL) |
| 100 | # define PREEMPT_INATOMIC_BASE kernel_locked() | 100 | # define PREEMPT_INATOMIC_BASE kernel_locked() |
| 101 | # define PREEMPT_CHECK_OFFSET 1 | ||
| 102 | #else | 101 | #else |
| 103 | # define PREEMPT_INATOMIC_BASE 0 | 102 | # define PREEMPT_INATOMIC_BASE 0 |
| 103 | #endif | ||
| 104 | |||
| 105 | #if defined(CONFIG_PREEMPT) | ||
| 106 | # define PREEMPT_CHECK_OFFSET 1 | ||
| 107 | #else | ||
| 104 | # define PREEMPT_CHECK_OFFSET 0 | 108 | # define PREEMPT_CHECK_OFFSET 0 |
| 105 | #endif | 109 | #endif |
| 106 | 110 | ||
diff --git a/include/linux/mmc/sh_mmcif.h b/include/linux/mmc/sh_mmcif.h index d19e2114fd86..5c99da1078aa 100644 --- a/include/linux/mmc/sh_mmcif.h +++ b/include/linux/mmc/sh_mmcif.h | |||
| @@ -59,19 +59,19 @@ struct sh_mmcif_plat_data { | |||
| 59 | #define MMCIF_CE_HOST_STS2 0x0000004C | 59 | #define MMCIF_CE_HOST_STS2 0x0000004C |
| 60 | #define MMCIF_CE_VERSION 0x0000007C | 60 | #define MMCIF_CE_VERSION 0x0000007C |
| 61 | 61 | ||
| 62 | extern inline u32 sh_mmcif_readl(void __iomem *addr, int reg) | 62 | static inline u32 sh_mmcif_readl(void __iomem *addr, int reg) |
| 63 | { | 63 | { |
| 64 | return readl(addr + reg); | 64 | return readl(addr + reg); |
| 65 | } | 65 | } |
| 66 | 66 | ||
| 67 | extern inline void sh_mmcif_writel(void __iomem *addr, int reg, u32 val) | 67 | static inline void sh_mmcif_writel(void __iomem *addr, int reg, u32 val) |
| 68 | { | 68 | { |
| 69 | writel(val, addr + reg); | 69 | writel(val, addr + reg); |
| 70 | } | 70 | } |
| 71 | 71 | ||
| 72 | #define SH_MMCIF_BBS 512 /* boot block size */ | 72 | #define SH_MMCIF_BBS 512 /* boot block size */ |
| 73 | 73 | ||
| 74 | extern inline void sh_mmcif_boot_cmd_send(void __iomem *base, | 74 | static inline void sh_mmcif_boot_cmd_send(void __iomem *base, |
| 75 | unsigned long cmd, unsigned long arg) | 75 | unsigned long cmd, unsigned long arg) |
| 76 | { | 76 | { |
| 77 | sh_mmcif_writel(base, MMCIF_CE_INT, 0); | 77 | sh_mmcif_writel(base, MMCIF_CE_INT, 0); |
| @@ -79,7 +79,7 @@ extern inline void sh_mmcif_boot_cmd_send(void __iomem *base, | |||
| 79 | sh_mmcif_writel(base, MMCIF_CE_CMD_SET, cmd); | 79 | sh_mmcif_writel(base, MMCIF_CE_CMD_SET, cmd); |
| 80 | } | 80 | } |
| 81 | 81 | ||
| 82 | extern inline int sh_mmcif_boot_cmd_poll(void __iomem *base, unsigned long mask) | 82 | static inline int sh_mmcif_boot_cmd_poll(void __iomem *base, unsigned long mask) |
| 83 | { | 83 | { |
| 84 | unsigned long tmp; | 84 | unsigned long tmp; |
| 85 | int cnt; | 85 | int cnt; |
| @@ -95,14 +95,14 @@ extern inline int sh_mmcif_boot_cmd_poll(void __iomem *base, unsigned long mask) | |||
| 95 | return -1; | 95 | return -1; |
| 96 | } | 96 | } |
| 97 | 97 | ||
| 98 | extern inline int sh_mmcif_boot_cmd(void __iomem *base, | 98 | static inline int sh_mmcif_boot_cmd(void __iomem *base, |
| 99 | unsigned long cmd, unsigned long arg) | 99 | unsigned long cmd, unsigned long arg) |
| 100 | { | 100 | { |
| 101 | sh_mmcif_boot_cmd_send(base, cmd, arg); | 101 | sh_mmcif_boot_cmd_send(base, cmd, arg); |
| 102 | return sh_mmcif_boot_cmd_poll(base, 0x00010000); | 102 | return sh_mmcif_boot_cmd_poll(base, 0x00010000); |
| 103 | } | 103 | } |
| 104 | 104 | ||
| 105 | extern inline int sh_mmcif_boot_do_read_single(void __iomem *base, | 105 | static inline int sh_mmcif_boot_do_read_single(void __iomem *base, |
| 106 | unsigned int block_nr, | 106 | unsigned int block_nr, |
| 107 | unsigned long *buf) | 107 | unsigned long *buf) |
| 108 | { | 108 | { |
| @@ -125,7 +125,7 @@ extern inline int sh_mmcif_boot_do_read_single(void __iomem *base, | |||
| 125 | return 0; | 125 | return 0; |
| 126 | } | 126 | } |
| 127 | 127 | ||
| 128 | extern inline int sh_mmcif_boot_do_read(void __iomem *base, | 128 | static inline int sh_mmcif_boot_do_read(void __iomem *base, |
| 129 | unsigned long first_block, | 129 | unsigned long first_block, |
| 130 | unsigned long nr_blocks, | 130 | unsigned long nr_blocks, |
| 131 | void *buf) | 131 | void *buf) |
| @@ -143,7 +143,7 @@ extern inline int sh_mmcif_boot_do_read(void __iomem *base, | |||
| 143 | return ret; | 143 | return ret; |
| 144 | } | 144 | } |
| 145 | 145 | ||
| 146 | extern inline void sh_mmcif_boot_init(void __iomem *base) | 146 | static inline void sh_mmcif_boot_init(void __iomem *base) |
| 147 | { | 147 | { |
| 148 | unsigned long tmp; | 148 | unsigned long tmp; |
| 149 | 149 | ||
| @@ -177,7 +177,7 @@ extern inline void sh_mmcif_boot_init(void __iomem *base) | |||
| 177 | sh_mmcif_boot_cmd(base, 0x03400040, 0x00010000); | 177 | sh_mmcif_boot_cmd(base, 0x03400040, 0x00010000); |
| 178 | } | 178 | } |
| 179 | 179 | ||
| 180 | extern inline void sh_mmcif_boot_slurp(void __iomem *base, | 180 | static inline void sh_mmcif_boot_slurp(void __iomem *base, |
| 181 | unsigned char *buf, | 181 | unsigned char *buf, |
| 182 | unsigned long no_bytes) | 182 | unsigned long no_bytes) |
| 183 | { | 183 | { |
diff --git a/include/linux/sh_clk.h b/include/linux/sh_clk.h index 4dca992f3093..cea0c38e7a63 100644 --- a/include/linux/sh_clk.h +++ b/include/linux/sh_clk.h | |||
| @@ -122,6 +122,10 @@ int clk_rate_table_find(struct clk *clk, | |||
| 122 | long clk_rate_div_range_round(struct clk *clk, unsigned int div_min, | 122 | long clk_rate_div_range_round(struct clk *clk, unsigned int div_min, |
| 123 | unsigned int div_max, unsigned long rate); | 123 | unsigned int div_max, unsigned long rate); |
| 124 | 124 | ||
| 125 | long clk_round_parent(struct clk *clk, unsigned long target, | ||
| 126 | unsigned long *best_freq, unsigned long *parent_freq, | ||
| 127 | unsigned int div_min, unsigned int div_max); | ||
| 128 | |||
| 125 | #define SH_CLK_MSTP32(_parent, _enable_reg, _enable_bit, _flags) \ | 129 | #define SH_CLK_MSTP32(_parent, _enable_reg, _enable_bit, _flags) \ |
| 126 | { \ | 130 | { \ |
| 127 | .parent = _parent, \ | 131 | .parent = _parent, \ |
diff --git a/include/linux/sh_timer.h b/include/linux/sh_timer.h index 864bd56bd3b0..4d9dcd138315 100644 --- a/include/linux/sh_timer.h +++ b/include/linux/sh_timer.h | |||
| @@ -5,7 +5,6 @@ struct sh_timer_config { | |||
| 5 | char *name; | 5 | char *name; |
| 6 | long channel_offset; | 6 | long channel_offset; |
| 7 | int timer_bit; | 7 | int timer_bit; |
| 8 | char *clk; | ||
| 9 | unsigned long clockevent_rating; | 8 | unsigned long clockevent_rating; |
| 10 | unsigned long clocksource_rating; | 9 | unsigned long clocksource_rating; |
| 11 | }; | 10 | }; |
