aboutsummaryrefslogtreecommitdiffstats
path: root/arch (follow)
AgeCommit message (Collapse)AuthorFilesLines
2007-04-27[AVR32] Don't enable clocks with no usersHaavard Skinnemoen2-1/+14
Bring the code that sets the initial PM clock masks in line with the comment preceding it by only enabling clocks that have users != 0. Fix SM clock definition and avr32_hpt_init() so that the SM and TC0 clocks keep ticking. Signed-off-by: Haavard Skinnemoen <hskinnemoen@atmel.com>
2007-04-27[AVR32] Put cpu in sleep 0 when idle.Hans-Christian Egtvedt2-7/+40
This patch puts the CPU in sleep 0 when doing nothing, idle. This will turn of the CPU clock and thus save power. The CPU is waken again when an interrupt occurs. Signed-off-by: Hans-Christian Egtvedt <hcegtvedt@atmel.com> Signed-off-by: Haavard Skinnemoen <hskinnemoen@atmel.com>
2007-04-27[AVR32] Change system timer from count-compare to Timer/Counter 0Hans-Christian Egtvedt4-73/+313
Due to limitation of the count-compare system timer (not able to count when CPU is in sleep), the system timer had to be changed to use a peripheral timer/counter. The old COUNT-COMPARE code is still present in time.c as weak functions. The new timer is added to the architecture directory. This patch sets up TC0 as system timer The new timer has been tested on AT32AP7000/ATSTK1000 at 100 Hz, 250 Hz, 300 Hz and 1000 Hz. For more details about the timer/counter see the datasheet for AT32AP700x available at http://www.atmel.com/dyn/products/product_card.asp?part_id=3903 Signed-off-by: Hans-Christian Egtvedt <hcegtvedt@atmel.com> Signed-off-by: Haavard Skinnemoen <hskinnemoen@atmel.com>
2007-04-27[AVR32] Add mach-specific KconfigHaavard Skinnemoen2-0/+9
Include at32ap-specific Kconfig file from top-level Kconfig file. The at32ap Kconfig is currently empty, but it will grow some machine- specific options soon. Signed-off-by: Haavard Skinnemoen <hskinnemoen@atmel.com>
2007-04-27[AVR32] Add nwait and tdf parameters to SMC configurationHans-Christian Egtvedt1-0/+23
Complete the SMC configuration code by adding nwait and tdf parameter. After this change, we support the same parameters as the hardware. Signed-off-by: Haavard Skinnemoen <hskinnemoen@atmel.com>
2007-04-27[AVR32] Add basic HMATRIX supportHaavard Skinnemoen2-0/+220
This adds register and clock definitions for the High-speed bus Matrix (HMATRIX) as well as a function that can be used to configure special EBI functionality like CompactFlash and NAND flash support. Signed-off-by: Haavard Skinnemoen <hskinnemoen@atmel.com>
2007-04-26[SPARC64]: Convert PCI over to generic struct iommu/strbuf.David S. Miller5-61/+59
Signed-off-by: David S. Miller <davem@davemloft.net>
2007-04-26[SPARC]: device_node name constification falloutStephen Rothwell2-5/+3
A couple of routines need their arguments to be const. Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au> Signed-off-by: David S. Miller <davem@davemloft.net>
2007-04-26[SPARC64]: Convert SBUS over to generic iommu/strbuf structs.David S. Miller1-97/+132
Signed-off-by: David S. Miller <davem@davemloft.net>
2007-04-26[SPARC64]: Consolidate {sbus,pci}_iommu_arena.David S. Miller3-14/+8
Move to asm-sparc64/iommu.h and rename to plain "iommu_arena". Signed-off-by: David S. Miller <davem@davemloft.net>
2007-04-26[SPARC64]: constify some paramaters of OF routinesStephen Rothwell1-4/+7
This starts bringing the PowerPC and Sparc64 implemetations back closer together. Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au> Signed-off-by: David S. Miller <davem@davemloft.net>
2007-04-26[SPARC64]: Fix PCI rework to adhere to of_get_property() const return.David S. Miller5-12/+12
Signed-off-by: David S. Miller <davem@davemloft.net>
2007-04-26[SPARC64]: Document and fix calculation of pages_avail.David S. Miller1-2/+23
It should be set to the total number of pages that the system will really have available after things like initmem, the bootmem map, and initrd are freed up. Signed-off-by: David S. Miller <davem@davemloft.net>
2007-04-26[SPARC64]: Make sure pbm->prom_node is setup easly enough in psycho.cDavid S. Miller1-2/+2
It needs to be ready before we invoke pci_determine_mem_io_space(). Signed-off-by: David S. Miller <davem@davemloft.net>
2007-04-26[SPARC64]: Use bootmem_bootmap_pages() in choose_bootmap_pfn().David S. Miller1-2/+2
Signed-off-by: David S. Miller <davem@davemloft.net>
2007-04-26[SPARC64]: Add proper header file extern for cmdline_memory_size.David S. Miller1-2/+0
Signed-off-by: David S. Miller <davem@davemloft.net>
2007-04-26[SPARC64]: Kill sparc_ultra_dump_{i,d}tlb()David S. Miller1-87/+0
While useful in odd circumstances to debug something, they are normally totally unused and anyone can fetch this code out of the history if they really need it. And in any event, the person who needs this kind of code is usually me :-) Signed-off-by: David S. Miller <davem@davemloft.net>
2007-04-26[SPARC64]: Use DECLARE_BITMAP and BITS_TO_LONGS in mm/init.cDavid S. Miller1-6/+7
Signed-off-by: David S. Miller <davem@davemloft.net>
2007-04-26[SPARC64]: Give move verbose show_mem() output just like i386.David S. Miller1-2/+37
We now report everything i386 does except for highmem which doesn't apply. Signed-off-by: David S. Miller <davem@davemloft.net>
2007-04-26[SPARC64]: Mark show_mem() printk's with KERN_INFO.David S. Miller1-4/+4
Signed-off-by: David S. Miller <davem@davemloft.net>
2007-04-26[SPARC64]: Kill kvaddr_to_phys() and friends.David S. Miller1-63/+28
Just inline it into flush_icache_range() which is the only user. Signed-off-by: David S. Miller <davem@davemloft.net>
2007-04-26[SPARC64]: Privatize sun4u_get_pte() and fix name.David S. Miller1-67/+62
__get_phys is only called from init.c as is prom_virt_to_phys(), __get_iospace() is not called at all, and sun4u_get_pte() is largely misnamed. Privatize the implementation and helper functions of sun4u_get_phys() to mm/init.c, and rename to kvaddr_to_paddr(). The only used of this thing is flush_icache_range(), and thus things can be considerably further simplified. For example, we should only see module or PAGE_OFFSET kernel addresses here, so we don't need the OBP firmware range handling at all. Signed-off-by: David S. Miller <davem@davemloft.net>
2007-04-26[SPARC64]: Kill _start[]/_end[] declarations in mm/init.cDavid S. Miller1-3/+0
We already get those from asm/sections.h Signed-off-by: David S. Miller <davem@davemloft.net>
2007-04-26[SPARC64]: Simplify read_obp_memory().David S. Miller1-16/+11
Kick out empty entries as soon as we spot them, and use memmove() instead of a silly loop to make the operation more clear. Signed-off-by: David S. Miller <davem@davemloft.net>
2007-04-26[SPARC64]: Use SPARSEMEM_STATICDavid S. Miller1-0/+1
Decrease the SECTION_SIZE_BITS --> MAX_PHYSADDR_BITS range a little bit. The cost of going to SPARSEMEM_STATIC becomes 8K of BSS space, and in return we save a pointer dereferences on every page struct lookup. Even better we hit the main kernel image for the base address which is in a hugepage locked TLB entry. Signed-off-by: David S. Miller <davem@davemloft.net>
2007-04-26[SPARC64]: Force dummy host controller onto bus zero.David S. Miller1-8/+10
This helps deal with the invisible bridge that sits between the host controller and the top-most visisble PCI devices on hypervisor systems. For example, on T1000 the bus-range property says 2 --> 4 and so there is a PCI express bridge at bus 2, devfn 0, etc. So if we don't force the dummy host controller to bus zero, we'll try to create two devices with the same domain/bus/devfn triplet. Also, add some more log diagnostics to make debugging stuff like this easyer. Signed-off-by: David S. Miller <davem@davemloft.net>
2007-04-26[SPARC64]: Add dummy host controller to root of all PCI domains.David S. Miller6-30/+129
We fake up a dummy one in all cases because that is the simplest thing to do and it happens to be necessary for hypervisor systems. Signed-off-by: David S. Miller <davem@davemloft.net>
2007-04-26[SPARC64]: Const'ify pci_iommu_ops.David S. Miller3-4/+4
Based upon a similar patch for x86_64 written by Stephen Hemminger. Signed-off-by: David S. Miller <davem@davemloft.net>
2007-04-26[SPARC64]: Kill pbm->pci_first_slot.David S. Miller5-14/+2
Set but never used. Signed-off-by: David S. Miller <davem@davemloft.net>
2007-04-26[SPARC64]: Kill pci_controller->pbms_same_domainDavid S. Miller4-66/+12
We don't do the "Simba APB is a PBM" bogosity for Sabre controllers any longer, so this pbms_same_domain thing is no longer necessary. Signed-off-by: David S. Miller <davem@davemloft.net>
2007-04-26[SPARC64]: Kill pci_controller->base_address_update().David S. Miller4-182/+0
Implemented but never actually used. Signed-off-by: David S. Miller <davem@davemloft.net>
2007-04-26[SPARC64]: Kill pci_controller->resource_adjust()David S. Miller5-49/+12
All the implementations can be identical and generic, so no need for controller specific methods. Signed-off-by: David S. Miller <davem@davemloft.net>
2007-04-26[SPARC64]: Kill PBM ranges software state.David S. Miller4-32/+15
It is only used in one spot and we can just fetch the OF property right there. Signed-off-by: David S. Miller <davem@davemloft.net>
2007-04-26[SPARC64]: Kill PBM intmap software state.David S. Miller3-28/+0
Set but never used. Signed-off-by: David S. Miller <davem@davemloft.net>
2007-04-26[SPARC64]: Consolidate PCI mem/io resource determination.David S. Miller6-218/+103
It can be done for every PCI configuration using OF properties. Signed-off-by: David S. Miller <davem@davemloft.net>
2007-04-26[SPARC64]: Fix sabre pci controllers with new probing scheme.David S. Miller3-284/+165
The SIMBA APB bridge is strange, it is a PCI bridge but it lacks some standard OF properties, in particular it lacks a 'ranges' property. What you have to do is read the IO and MEM range registers in the APB bridge to determine the ranges handled by each bridge. So fill in the bus resources by doing that. Since we now handle this quirk in the generic PCI and OF device probing layers, we can flat out eliminate all of that code from the sabre pci controller driver. In fact we can thus eliminate completely another quirk of the sabre driver. It tried to make the two APB bridges look like PBMs but that makes zero sense now (and it's questionable whether it ever made sense). So now just use pbm_A and probe the whole PCI hierarchy using that as the root. This simplification allows many future cleanups to occur. Also, I've found yet another quirk that needs to be worked around while testing this. You can't use the 'class-code' OF firmware property, especially for IDE controllers. We have to read the value out of PCI config space or else we'll see the value the device was showing before it was programmed into native mode. I'm starting to think it might be wise to just read all of the values out of PCI config space instead of using the OF properties. :-/ Signed-off-by: David S. Miller <davem@davemloft.net>
2007-04-26[SPARC64]: Fix obppath pci device sysfs creation.David S. Miller1-0/+3
Need to traverse recursively down child busses else we only get the file created under devices at the top-level. Signed-off-by: David S. Miller <davem@davemloft.net>
2007-04-26[SPARC64]: Minor cleanups to schizo pci controller driver.David S. Miller1-79/+31
Signed-off-by: David S. Miller <davem@davemloft.net>
2007-04-26[SPARC64]: Internalize pci_memspace_mask.David S. Miller3-1/+3
The only user was bus_dvma_to_mem() which is no longer used by any driver, so kill that, and the export of pci_memspace_mask. The only user now is the PCI mmap support code. Signed-off-by: David S. Miller <davem@davemloft.net>
2007-04-26[SPARC64]: Probe PCI bus using OF device tree.David S. Miller8-1039/+409
Almost entirely taken from the 64-bit PowerPC PCI code. This allowed to eliminate a ton of cruft from the sparc64 PCI layer. Signed-off-by: David S. Miller <davem@davemloft.net>
2007-04-26[SPARC64] isa: Convert to use pci_device_to_OF_node().David S. Miller1-32/+4
Also, do not try to compute resources by hand, instead use the pre-computed ones in the of_device. Signed-off-by: David S. Miller <davem@davemloft.net>
2007-04-26[SPARC64] ebus: Convert to use pci_device_to_OF_node().David S. Miller1-9/+3
Also, we don't need to store or use the PBM so kill that from the linux_ebus. Signed-off-by: David S. Miller <davem@davemloft.net>
2007-04-26[SPARC]: Use strcasecmp for OFW property name comparisons.David S. Miller2-4/+4
This allows us to simplify sharing code with powerpc which has properties that have various forms of capitalization when on the sparc64 side the property is all lower-case. Signed-off-by: David S. Miller <davem@davemloft.net>
2007-04-26[STRING]: Move strcasecmp/strncasecmp to lib/string.cDavid S. Miller12-144/+5
We have several platforms using local copies of identical code. Signed-off-by: David S. Miller <davem@davemloft.net>
2007-04-26[SPARC]: constify some paramaters of OF routinesStephen Rothwell1-3/+6
This starts bringing the PowerPC and Sparc implemetations back closer together. Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au> Signed-off-by: David S. Miller <davem@davemloft.net>
2007-04-26[SPARC/64]: constify of_get_property returnStephen Rothwell2-2/+2
Finally, we actually change the functions themselves. Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au> Signed-off-by: David S. Miller <davem@davemloft.net>
2007-04-26[SPARC64]: constify of_get_property return: arch/sparc64Stephen Rothwell11-43/+46
Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au> Signed-off-by: David S. Miller <davem@davemloft.net>
2007-04-26[SPARC]: constify of_get_property return: arch/sparcStephen Rothwell4-19/+20
Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au> Signed-off-by: David S. Miller <davem@davemloft.net>
2007-04-26[SPARC64]: Small cleanups time.cTony Breeds1-11/+6
- Removes days_in_mo[], as it's almost identical to month_days[] - Use the leapyear() macro - Line length wrapping. Signed-off-by: Tony Breeds <tony@bakeyournoodle.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2007-04-26[SPARC64]: Fix sparc64_next_event() error return.David S. Miller1-1/+1
It should return an error code not a boolean. Based upon an hpet timer fix by Thomas Gleixner. Signed-off-by: David S. Miller <davem@davemloft.net>