Lines Matching +full:a +full:- +full:z
4 * Copyright (C) 1995-2003 Geert Uytterhoeven
19 #include <linux/dma-mapping.h>
54 struct zorro_dev *z; in zorro_find_device() local
59 for (z = from ? from+1 : &zorro_autocon[0]; in zorro_find_device()
60 z < zorro_autocon+zorro_num_autocon; in zorro_find_device()
61 z++) in zorro_find_device()
62 if (id == ZORRO_WILDCARD || id == z->id) in zorro_find_device()
63 return z; in zorro_find_device()
71 * by the system. Every bit represents a 64K chunk, for a maximum of 8MB
72 * (128 chunks, physical 0x00200000-0x009fffff).
78 * - z2ram device
79 * - SCSI DMA bounce buffers
100 start = start < Z2RAM_START ? 0x00000000 : start-Z2RAM_START; in mark_region()
101 end = end > Z2RAM_END ? Z2RAM_SIZE : end-Z2RAM_START; in mark_region()
115 struct platform_device *bridge, struct zorro_dev *z) in zorro_find_parent_resource() argument
119 for (i = 0; i < bridge->num_resources; i++) { in zorro_find_parent_resource()
120 struct resource *r = &bridge->resource[i]; in zorro_find_parent_resource()
122 if (zorro_resource_start(z) >= r->start && in zorro_find_parent_resource()
123 zorro_resource_end(z) <= r->end) in zorro_find_parent_resource()
135 struct zorro_dev *z; in amiga_zorro_probe() local
144 return -ENOMEM; in amiga_zorro_probe()
146 zorro_autocon = bus->devices; in amiga_zorro_probe()
147 bus->dev.parent = &pdev->dev; in amiga_zorro_probe()
148 dev_set_name(&bus->dev, zorro_bus_type.name); in amiga_zorro_probe()
149 error = device_register(&bus->dev); in amiga_zorro_probe()
152 put_device(&bus->dev); in amiga_zorro_probe()
164 z = &zorro_autocon[i]; in amiga_zorro_probe()
166 z->rom = zi->rom; in amiga_zorro_probe()
167 z->id = (be16_to_cpu(z->rom.er_Manufacturer) << 16) | in amiga_zorro_probe()
168 (z->rom.er_Product << 8); in amiga_zorro_probe()
169 if (z->id == ZORRO_PROD_GVP_EPC_BASE) { in amiga_zorro_probe()
171 unsigned long magic = zi->boardaddr + 0x8000; in amiga_zorro_probe()
173 z->id |= *(u16 *)ZTWO_VADDR(magic) & GVP_PRODMASK; in amiga_zorro_probe()
175 z->slotaddr = zi->slotaddr; in amiga_zorro_probe()
176 z->slotsize = zi->slotsize; in amiga_zorro_probe()
177 sprintf(z->name, "Zorro device %08x", z->id); in amiga_zorro_probe()
178 zorro_name_device(z); in amiga_zorro_probe()
179 z->resource.start = zi->boardaddr; in amiga_zorro_probe()
180 z->resource.end = zi->boardaddr + zi->boardsize - 1; in amiga_zorro_probe()
181 z->resource.name = z->name; in amiga_zorro_probe()
182 r = zorro_find_parent_resource(pdev, z); in amiga_zorro_probe()
183 error = request_resource(r, &z->resource); in amiga_zorro_probe()
184 if (error && !(z->rom.er_Type & ERTF_MEMLIST)) in amiga_zorro_probe()
185 dev_err(&bus->dev, in amiga_zorro_probe()
187 z->name, &z->resource); in amiga_zorro_probe()
188 z->dev.parent = &bus->dev; in amiga_zorro_probe()
189 z->dev.bus = &zorro_bus_type; in amiga_zorro_probe()
190 z->dev.id = i; in amiga_zorro_probe()
191 switch (z->rom.er_Type & ERT_TYPEMASK) { in amiga_zorro_probe()
193 z->dev.coherent_dma_mask = DMA_BIT_MASK(32); in amiga_zorro_probe()
198 z->dev.coherent_dma_mask = DMA_BIT_MASK(24); in amiga_zorro_probe()
201 z->dev.dma_mask = &z->dev.coherent_dma_mask; in amiga_zorro_probe()
206 z = &zorro_autocon[i]; in amiga_zorro_probe()
207 error = device_register(&z->dev); in amiga_zorro_probe()
209 dev_err(&bus->dev, "Error registering device %s\n", in amiga_zorro_probe()
210 z->name); in amiga_zorro_probe()
211 put_device(&z->dev); in amiga_zorro_probe()
217 zorro_for_each_dev(z) { in amiga_zorro_probe()
218 if (z->rom.er_Type & ERTF_MEMLIST) in amiga_zorro_probe()
219 mark_region(zorro_resource_start(z), in amiga_zorro_probe()
220 zorro_resource_end(z)+1, 1); in amiga_zorro_probe()
235 .name = "amiga-zorro",