Changeset 98000fb in mainline for kernel/generic/src/ddi
- Timestamp:
- 2009-06-03T19:34:45Z (17 years ago)
- Branches:
- lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
- Children:
- 301ff30
- Parents:
- 69e68e3
- Location:
- kernel/generic/src/ddi
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
kernel/generic/src/ddi/ddi.c
r69e68e3 r98000fb 98 98 * 99 99 */ 100 static int ddi_physmem_map(uintptr_t pf, uintptr_t vp, count_t pages, int flags)100 static int ddi_physmem_map(uintptr_t pf, uintptr_t vp, size_t pages, int flags) 101 101 { 102 102 ASSERT(TASK); … … 119 119 /* Find the zone of the physical memory */ 120 120 spinlock_lock(&zones.lock); 121 count_t znum = find_zone(ADDR2PFN(pf), pages, 0);122 123 if (znum == ( count_t) -1) {121 size_t znum = find_zone(ADDR2PFN(pf), pages, 0); 122 123 if (znum == (size_t) -1) { 124 124 /* Frames not found in any zones 125 125 * -> assume it is hardware device and allow mapping … … 243 243 return (unative_t) ddi_physmem_map(ALIGN_DOWN((uintptr_t) phys_base, 244 244 FRAME_SIZE), ALIGN_DOWN((uintptr_t) virt_base, PAGE_SIZE), 245 ( count_t) pages, (int) flags);245 (size_t) pages, (int) flags); 246 246 } 247 247 -
kernel/generic/src/ddi/irq.c
r69e68e3 r98000fb 100 100 * there will be collisions between different keys. 101 101 */ 102 static index_t irq_ht_hash(unative_t *key);103 static bool irq_ht_compare(unative_t *key, count_t keys, link_t *item);102 static size_t irq_ht_hash(unative_t *key); 103 static bool irq_ht_compare(unative_t *key, size_t keys, link_t *item); 104 104 static void irq_ht_remove(link_t *item); 105 105 … … 116 116 * elements with single key (sharing of one IRQ). 117 117 */ 118 static index_t irq_lin_hash(unative_t *key);119 static bool irq_lin_compare(unative_t *key, count_t keys, link_t *item);118 static size_t irq_lin_hash(unative_t *key); 119 static bool irq_lin_compare(unative_t *key, size_t keys, link_t *item); 120 120 static void irq_lin_remove(link_t *item); 121 121 … … 127 127 128 128 /** Number of buckets in either of the hash tables. */ 129 static count_t buckets;129 static size_t buckets; 130 130 131 131 /** Initialize IRQ subsystem. … … 134 134 * @param chains Number of chains in the hash table. 135 135 */ 136 void irq_init( count_t inrs, count_t chains)136 void irq_init(size_t inrs, size_t chains) 137 137 { 138 138 buckets = chains; … … 299 299 * @return Index into the hash table. 300 300 */ 301 index_t irq_ht_hash(unative_t key[])301 size_t irq_ht_hash(unative_t key[]) 302 302 { 303 303 inr_t inr = (inr_t) key[KEY_INR]; … … 325 325 * @return True on match or false otherwise. 326 326 */ 327 bool irq_ht_compare(unative_t key[], count_t keys, link_t *item)327 bool irq_ht_compare(unative_t key[], size_t keys, link_t *item) 328 328 { 329 329 irq_t *irq = hash_table_get_instance(item, irq_t, link); … … 372 372 * @return Index into the hash table. 373 373 */ 374 index_t irq_lin_hash(unative_t key[])374 size_t irq_lin_hash(unative_t key[]) 375 375 { 376 376 inr_t inr = (inr_t) key[KEY_INR]; … … 398 398 * @return True on match or false otherwise. 399 399 */ 400 bool irq_lin_compare(unative_t key[], count_t keys, link_t *item)400 bool irq_lin_compare(unative_t key[], size_t keys, link_t *item) 401 401 { 402 402 irq_t *irq = list_get_instance(item, irq_t, link);
Note:
See TracChangeset
for help on using the changeset viewer.
