aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/staging
diff options
context:
space:
mode:
authorOmar Ramirez Luna <omar.ramirez@copitl.com>2012-10-24 18:09:16 -0400
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2012-10-24 19:31:31 -0400
commit53e3e3f19f3a0c4c38e28eb4af7acfee325db375 (patch)
treee0ffd1bf17d39bd2d40331f183377119cd183fc8 /drivers/staging
parentb8cac0bbed33065ac42b3791efefec5dc233f7c1 (diff)
staging: tidspbridge: drop const from custom mmu implementation
Custom mmu functions receive a 'const void __iomem *', all the callers pass a 'void __iomem *', so drop the const to fix the warnings like: warning: passing argument 2 of '__raw_writel' discards qualifiers from pointer target type ../io.h:88: note: expected 'volatile void *' but argument is of type 'const void *' Signed-off-by: Omar Ramirez Luna <omar.ramirez@copitl.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/staging')
-rw-r--r--drivers/staging/tidspbridge/hw/hw_mmu.c40
-rw-r--r--drivers/staging/tidspbridge/hw/hw_mmu.h28
2 files changed, 34 insertions, 34 deletions
diff --git a/drivers/staging/tidspbridge/hw/hw_mmu.c b/drivers/staging/tidspbridge/hw/hw_mmu.c
index 71cb8229364..a1594504ad5 100644
--- a/drivers/staging/tidspbridge/hw/hw_mmu.c
+++ b/drivers/staging/tidspbridge/hw/hw_mmu.c
@@ -78,7 +78,7 @@ static hw_status mmu_flush_entry(const void __iomem *base_address);
78 * INPUTS: 78 * INPUTS:
79 * 79 *
80 * Identifier : base_address 80 * Identifier : base_address
81 * TypE : const u32 81 * Type : void __iomem *
82 * Description : Base Address of instance of MMU module 82 * Description : Base Address of instance of MMU module
83 * 83 *
84 * Identifier : page_sz 84 * Identifier : page_sz
@@ -112,7 +112,7 @@ static hw_status mmu_flush_entry(const void __iomem *base_address);
112 * 112 *
113 * METHOD: : Check the Input parameters and set the CAM entry. 113 * METHOD: : Check the Input parameters and set the CAM entry.
114 */ 114 */
115static hw_status mmu_set_cam_entry(const void __iomem *base_address, 115static hw_status mmu_set_cam_entry(void __iomem *base_address,
116 const u32 page_sz, 116 const u32 page_sz,
117 const u32 preserved_bit, 117 const u32 preserved_bit,
118 const u32 valid_bit, 118 const u32 valid_bit,
@@ -124,7 +124,7 @@ static hw_status mmu_set_cam_entry(const void __iomem *base_address,
124 * INPUTS: 124 * INPUTS:
125 * 125 *
126 * Identifier : base_address 126 * Identifier : base_address
127 * Type : const u32 127 * Type : void __iomem *
128 * Description : Base Address of instance of MMU module 128 * Description : Base Address of instance of MMU module
129 * 129 *
130 * Identifier : physical_addr 130 * Identifier : physical_addr
@@ -157,7 +157,7 @@ static hw_status mmu_set_cam_entry(const void __iomem *base_address,
157 * 157 *
158 * METHOD: : Check the Input parameters and set the RAM entry. 158 * METHOD: : Check the Input parameters and set the RAM entry.
159 */ 159 */
160static hw_status mmu_set_ram_entry(const void __iomem *base_address, 160static hw_status mmu_set_ram_entry(void __iomem *base_address,
161 const u32 physical_addr, 161 const u32 physical_addr,
162 enum hw_endianism_t endianism, 162 enum hw_endianism_t endianism,
163 enum hw_element_size_t element_size, 163 enum hw_element_size_t element_size,
@@ -165,7 +165,7 @@ static hw_status mmu_set_ram_entry(const void __iomem *base_address,
165 165
166/* HW FUNCTIONS */ 166/* HW FUNCTIONS */
167 167
168hw_status hw_mmu_enable(const void __iomem *base_address) 168hw_status hw_mmu_enable(void __iomem *base_address)
169{ 169{
170 hw_status status = 0; 170 hw_status status = 0;
171 171
@@ -174,7 +174,7 @@ hw_status hw_mmu_enable(const void __iomem *base_address)
174 return status; 174 return status;
175} 175}
176 176
177hw_status hw_mmu_disable(const void __iomem *base_address) 177hw_status hw_mmu_disable(void __iomem *base_address)
178{ 178{
179 hw_status status = 0; 179 hw_status status = 0;
180 180
@@ -183,7 +183,7 @@ hw_status hw_mmu_disable(const void __iomem *base_address)
183 return status; 183 return status;
184} 184}
185 185
186hw_status hw_mmu_num_locked_set(const void __iomem *base_address, 186hw_status hw_mmu_num_locked_set(void __iomem *base_address,
187 u32 num_locked_entries) 187 u32 num_locked_entries)
188{ 188{
189 hw_status status = 0; 189 hw_status status = 0;
@@ -193,7 +193,7 @@ hw_status hw_mmu_num_locked_set(const void __iomem *base_address,
193 return status; 193 return status;
194} 194}
195 195
196hw_status hw_mmu_victim_num_set(const void __iomem *base_address, 196hw_status hw_mmu_victim_num_set(void __iomem *base_address,
197 u32 victim_entry_num) 197 u32 victim_entry_num)
198{ 198{
199 hw_status status = 0; 199 hw_status status = 0;
@@ -203,7 +203,7 @@ hw_status hw_mmu_victim_num_set(const void __iomem *base_address,
203 return status; 203 return status;
204} 204}
205 205
206hw_status hw_mmu_event_ack(const void __iomem *base_address, u32 irq_mask) 206hw_status hw_mmu_event_ack(void __iomem *base_address, u32 irq_mask)
207{ 207{
208 hw_status status = 0; 208 hw_status status = 0;
209 209
@@ -212,7 +212,7 @@ hw_status hw_mmu_event_ack(const void __iomem *base_address, u32 irq_mask)
212 return status; 212 return status;
213} 213}
214 214
215hw_status hw_mmu_event_disable(const void __iomem *base_address, u32 irq_mask) 215hw_status hw_mmu_event_disable(void __iomem *base_address, u32 irq_mask)
216{ 216{
217 hw_status status = 0; 217 hw_status status = 0;
218 u32 irq_reg; 218 u32 irq_reg;
@@ -224,7 +224,7 @@ hw_status hw_mmu_event_disable(const void __iomem *base_address, u32 irq_mask)
224 return status; 224 return status;
225} 225}
226 226
227hw_status hw_mmu_event_enable(const void __iomem *base_address, u32 irq_mask) 227hw_status hw_mmu_event_enable(void __iomem *base_address, u32 irq_mask)
228{ 228{
229 hw_status status = 0; 229 hw_status status = 0;
230 u32 irq_reg; 230 u32 irq_reg;
@@ -236,7 +236,7 @@ hw_status hw_mmu_event_enable(const void __iomem *base_address, u32 irq_mask)
236 return status; 236 return status;
237} 237}
238 238
239hw_status hw_mmu_event_status(const void __iomem *base_address, u32 *irq_mask) 239hw_status hw_mmu_event_status(void __iomem *base_address, u32 *irq_mask)
240{ 240{
241 hw_status status = 0; 241 hw_status status = 0;
242 242
@@ -245,7 +245,7 @@ hw_status hw_mmu_event_status(const void __iomem *base_address, u32 *irq_mask)
245 return status; 245 return status;
246} 246}
247 247
248hw_status hw_mmu_fault_addr_read(const void __iomem *base_address, u32 *addr) 248hw_status hw_mmu_fault_addr_read(void __iomem *base_address, u32 *addr)
249{ 249{
250 hw_status status = 0; 250 hw_status status = 0;
251 251
@@ -255,7 +255,7 @@ hw_status hw_mmu_fault_addr_read(const void __iomem *base_address, u32 *addr)
255 return status; 255 return status;
256} 256}
257 257
258hw_status hw_mmu_ttb_set(const void __iomem *base_address, u32 ttb_phys_addr) 258hw_status hw_mmu_ttb_set(void __iomem *base_address, u32 ttb_phys_addr)
259{ 259{
260 hw_status status = 0; 260 hw_status status = 0;
261 u32 load_ttb; 261 u32 load_ttb;
@@ -267,7 +267,7 @@ hw_status hw_mmu_ttb_set(const void __iomem *base_address, u32 ttb_phys_addr)
267 return status; 267 return status;
268} 268}
269 269
270hw_status hw_mmu_twl_enable(const void __iomem *base_address) 270hw_status hw_mmu_twl_enable(void __iomem *base_address)
271{ 271{
272 hw_status status = 0; 272 hw_status status = 0;
273 273
@@ -276,7 +276,7 @@ hw_status hw_mmu_twl_enable(const void __iomem *base_address)
276 return status; 276 return status;
277} 277}
278 278
279hw_status hw_mmu_twl_disable(const void __iomem *base_address) 279hw_status hw_mmu_twl_disable(void __iomem *base_address)
280{ 280{
281 hw_status status = 0; 281 hw_status status = 0;
282 282
@@ -323,7 +323,7 @@ hw_status hw_mmu_tlb_flush(const void __iomem *base_address, u32 virtual_addr,
323 return status; 323 return status;
324} 324}
325 325
326hw_status hw_mmu_tlb_add(const void __iomem *base_address, 326hw_status hw_mmu_tlb_add(void __iomem *base_address,
327 u32 physical_addr, 327 u32 physical_addr,
328 u32 virtual_addr, 328 u32 virtual_addr,
329 u32 page_sz, 329 u32 page_sz,
@@ -516,7 +516,7 @@ static hw_status mmu_flush_entry(const void __iomem *base_address)
516} 516}
517 517
518/* mmu_set_cam_entry */ 518/* mmu_set_cam_entry */
519static hw_status mmu_set_cam_entry(const void __iomem *base_address, 519static hw_status mmu_set_cam_entry(void __iomem *base_address,
520 const u32 page_sz, 520 const u32 page_sz,
521 const u32 preserved_bit, 521 const u32 preserved_bit,
522 const u32 valid_bit, 522 const u32 valid_bit,
@@ -536,7 +536,7 @@ static hw_status mmu_set_cam_entry(const void __iomem *base_address,
536} 536}
537 537
538/* mmu_set_ram_entry */ 538/* mmu_set_ram_entry */
539static hw_status mmu_set_ram_entry(const void __iomem *base_address, 539static hw_status mmu_set_ram_entry(void __iomem *base_address,
540 const u32 physical_addr, 540 const u32 physical_addr,
541 enum hw_endianism_t endianism, 541 enum hw_endianism_t endianism,
542 enum hw_element_size_t element_size, 542 enum hw_element_size_t element_size,
@@ -556,7 +556,7 @@ static hw_status mmu_set_ram_entry(const void __iomem *base_address,
556 556
557} 557}
558 558
559void hw_mmu_tlb_flush_all(const void __iomem *base) 559void hw_mmu_tlb_flush_all(void __iomem *base)
560{ 560{
561 __raw_writel(1, base + MMU_GFLUSH); 561 __raw_writel(1, base + MMU_GFLUSH);
562} 562}
diff --git a/drivers/staging/tidspbridge/hw/hw_mmu.h b/drivers/staging/tidspbridge/hw/hw_mmu.h
index 1458a2c6027..1cdd0827beb 100644
--- a/drivers/staging/tidspbridge/hw/hw_mmu.h
+++ b/drivers/staging/tidspbridge/hw/hw_mmu.h
@@ -42,44 +42,44 @@ struct hw_mmu_map_attrs_t {
42 bool donotlockmpupage; 42 bool donotlockmpupage;
43}; 43};
44 44
45extern hw_status hw_mmu_enable(const void __iomem *base_address); 45extern hw_status hw_mmu_enable(void __iomem *base_address);
46 46
47extern hw_status hw_mmu_disable(const void __iomem *base_address); 47extern hw_status hw_mmu_disable(void __iomem *base_address);
48 48
49extern hw_status hw_mmu_num_locked_set(const void __iomem *base_address, 49extern hw_status hw_mmu_num_locked_set(void __iomem *base_address,
50 u32 num_locked_entries); 50 u32 num_locked_entries);
51 51
52extern hw_status hw_mmu_victim_num_set(const void __iomem *base_address, 52extern hw_status hw_mmu_victim_num_set(void __iomem *base_address,
53 u32 victim_entry_num); 53 u32 victim_entry_num);
54 54
55/* For MMU faults */ 55/* For MMU faults */
56extern hw_status hw_mmu_event_ack(const void __iomem *base_address, 56extern hw_status hw_mmu_event_ack(void __iomem *base_address,
57 u32 irq_mask); 57 u32 irq_mask);
58 58
59extern hw_status hw_mmu_event_disable(const void __iomem *base_address, 59extern hw_status hw_mmu_event_disable(void __iomem *base_address,
60 u32 irq_mask); 60 u32 irq_mask);
61 61
62extern hw_status hw_mmu_event_enable(const void __iomem *base_address, 62extern hw_status hw_mmu_event_enable(void __iomem *base_address,
63 u32 irq_mask); 63 u32 irq_mask);
64 64
65extern hw_status hw_mmu_event_status(const void __iomem *base_address, 65extern hw_status hw_mmu_event_status(void __iomem *base_address,
66 u32 *irq_mask); 66 u32 *irq_mask);
67 67
68extern hw_status hw_mmu_fault_addr_read(const void __iomem *base_address, 68extern hw_status hw_mmu_fault_addr_read(void __iomem *base_address,
69 u32 *addr); 69 u32 *addr);
70 70
71/* Set the TT base address */ 71/* Set the TT base address */
72extern hw_status hw_mmu_ttb_set(const void __iomem *base_address, 72extern hw_status hw_mmu_ttb_set(void __iomem *base_address,
73 u32 ttb_phys_addr); 73 u32 ttb_phys_addr);
74 74
75extern hw_status hw_mmu_twl_enable(const void __iomem *base_address); 75extern hw_status hw_mmu_twl_enable(void __iomem *base_address);
76 76
77extern hw_status hw_mmu_twl_disable(const void __iomem *base_address); 77extern hw_status hw_mmu_twl_disable(void __iomem *base_address);
78 78
79extern hw_status hw_mmu_tlb_flush(const void __iomem *base_address, 79extern hw_status hw_mmu_tlb_flush(const void __iomem *base_address,
80 u32 virtual_addr, u32 page_sz); 80 u32 virtual_addr, u32 page_sz);
81 81
82extern hw_status hw_mmu_tlb_add(const void __iomem *base_address, 82extern hw_status hw_mmu_tlb_add(void __iomem *base_address,
83 u32 physical_addr, 83 u32 physical_addr,
84 u32 virtual_addr, 84 u32 virtual_addr,
85 u32 page_sz, 85 u32 page_sz,
@@ -97,7 +97,7 @@ extern hw_status hw_mmu_pte_set(const u32 pg_tbl_va,
97extern hw_status hw_mmu_pte_clear(const u32 pg_tbl_va, 97extern hw_status hw_mmu_pte_clear(const u32 pg_tbl_va,
98 u32 virtual_addr, u32 page_size); 98 u32 virtual_addr, u32 page_size);
99 99
100void hw_mmu_tlb_flush_all(const void __iomem *base); 100void hw_mmu_tlb_flush_all(void __iomem *base);
101 101
102static inline u32 hw_mmu_pte_addr_l1(u32 l1_base, u32 va) 102static inline u32 hw_mmu_pte_addr_l1(u32 l1_base, u32 va)
103{ 103{