summaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
2011-02-23Merge branch 'for-linaro-2.6.38/dirty/arm/omap-thumb2+merged' of ↵linaro-linux-2.6.38-upstream-23Feb2011Nicolas Pitre
git://git.linaro.org/people/dmart/linux-2.6-arm into linaro-2.6.38
2011-02-23ARM: Thumb-2: Reflect ARM/Thumb-2 configuration in module vermagicDave Martin
Loading Thumb-2 modules into an ARM kernel or vice-versa isn't guaranteed to work safely, since the kernel is not interworking- aware everywhere. This patch adds "thumb2" to the module vermagic when CONFIG_THUMB2_KERNEL is enabled, to help avoid accidental loading of modules into the wrong kernel. Signed-off-by: Dave Martin <dave.martin@linaro.org> Acked-by: Nicolas Pitre <nicolas.pitre@linaro.org>
2011-02-23ARM: omap3: Work around assembler errors in sleep34xx.SDave Martin
In rare cases, gas is unable to fix up references to global symbols in the same object when building for Thumb-2. This patch provides a dirty temporary workaround and shouldn't be merged upstream. The issue affects at least ubuntu/linaro binutils (2.20.51.20100908-0ubuntu2) and binutils upstream. Allegedly, there's a fix in the pipeline. Signed-off-by: Dave Martin <dave.martin@linaro.org>
2011-02-23ARM: Add local symbols in relocate_kernel.S to work around gas bugsDave Martin
In rare cases, gas is unable to fix up references to global symbols in the same object when building for Thumb-2. This patch provides a dirty temporary workaround and shouldn't be merged upstream. The issue affects at least ubuntu/linaro binutils (2.20.51.20100908-0ubuntu2) and binutils upstream. Allegedly, there's a fix in the pipeline. Since this patch works around a known toolchain bug, it is not expected to merge upstream. Signed-off-by: Dave Martin <dave.martin@linaro.org>
2011-02-23OMAP: fix fncpy API callJean Pihet
Fix a potential problem with function types when calling the fncpy API to copy the PM code functions to SRAM. Signed-off-by: Jean Pihet <j-pihet@ti.com>
2011-02-23omap: use fncpy to copy the PM code functions to SRAMJean Pihet
The new fncpy API is better suited for copying some code to SRAM at runtime. This patch changes the ad-hoc code to the more generic fncpy API. Tested OK on OMAP3 in low power modes (RET/OFF) using omap2plus_defconfig with !CONFIG_THUMB2_KERNEL. Compile tested on OMAP1/2 using omap1_defconfig. Signed-off-by: Jean Pihet <j-pihet@ti.com> Acked-by: Kevin Hilman <khilman@ti.com> Tested-by: Kevin Hilman <khilman@ti.com>
2011-02-23ARM: Thumb-2: Symbol manipulation macros for function body copyingDave Martin
In low-level board support code, there is sometimes a need to copy a function body to another location at run-time. A straightforward call to memcpy doesn't work in Thumb-2, because bit 0 of external Thumb function symbols is set to 1, indicating that the function is Thumb. Without corrective measures, this will cause an off-by-one copy, and the copy may be called using the wrong instruction set. This patch adds an fncpy() macro to help with such copies. Particular care is needed, because C doesn't guarantee any defined behaviour when casting a function pointer to any other type. This has been observed to lead to strange optimisation side-effects when doing the arithmetic which is required in order to copy/move function bodies correctly in Thumb-2. Thanks to Russell King and Nicolas Pitre for their input on this patch. Signed-off-by: Dave Martin <dave.martin@linaro.org> Tested-by: Jean Pihet <j-pihet@ti.com> Tested-by: Tony Lindgren <tony@atomide.com> Tested-by: Kevin Hilman <khilman@ti.com>
2011-02-23ARM: omap3: Thumb-2 compatibility for sleep34xx.SDave Martin
* Build unconditionally as ARM for correct interoperation with OMAP firmware. * Fix an out-of-range ADR when building for ARM. * Remove deprecated PC-relative stores. * Add the required ENDPROC() directive for each ENTRY(). * .align before data words. * Handle non-interworking return from v7_flush_dcache_all. Jean Pihet: Tested OK on OMAP3 with and without CONFIG_THUMB2_KERNEL set. PM RETention and OFF modes in cpuidle OK. Signed-off-by: Dave Martin <dave.martin@linaro.org> Reviewed-by: Jean Pihet <j-pihet@ti.com> Tested-by: Jean Pihet <j-pihet@ti.com>
2011-02-23ARM: omap3: Thumb-2 compatibility for sram34xx.SDave Martin
* Build unconditionally as ARM for correct interoperation with OMAP firmware. * Remove deprecated PC-relative stores * Add the required ENDPROC() directive for each ENTRY(). * .align before data words Signed-off-by: Dave Martin <dave.martin@linaro.org>
2011-02-23ARM: omap3: Remove hand-encoded SMC instructionsDave Martin
For various reasons, Linux now only officially supports being built with tools which are new enough to understand the SMC instruction. Replacing the hand-encoded instructions when the mnemonic also allows for correct assembly in Thumb-2 (otherwise, the result is random data in the middle of the code). The Makefile already ensures that this file is built with a high enough gcc -march= flag (armv7-a). Jean Pihet: Tested OK on OMAP3 with and without CONFIG_THUMB2_KERNEL set. PM RETention and OFF modes in cpuidle OK. Signed-off-by: Dave Martin <dave.martin@linaro.org> Tested-by: Santosh Shilimkar <santosh.shilimkar@ti.com> Reviewed-by: Jean Pihet <j-pihet@ti.com> Tested-by: Jean Pihet <j-pihet@ti.com>
2011-02-23ARM: omap4: Convert END() to ENDPROC() for correct linkage with ↵Dave Martin
CONFIG_THUMB2_KERNEL Code marked with ENTRY() also needs a matching ENDPROC() directive, in order to ensure that the type and instruction set of the symbol are correctly annotated. ENDPROC() tags the affected symbol as a function symbol, which will ensure that link-time fixups don't accidentally switch to the wrong instruction set. Signed-off-by: Dave Martin <dave.martin@linaro.org> Tested-by: Santosh Shilimkar <santosh.shilimkar@ti.com> Acked-by: Santosh Shilimkar <santosh.shilimkar@ti.com>
2011-02-23ARM: omap4: Provide do_wfi() for Thumb-2Dave Martin
For CONFIG_THUMB2_KERNEL, the existing definition of do_wfi() will insert invalid code into the instruction stream. Any assembler which can assemble Thumb-2 is guaranteed to accept the "wfi" mnemonic, so for the Thumb-2 case, just use the mnemonic. The ARM case is left as-is. Signed-off-by: Dave Martin <dave.martin@linaro.org>
2011-02-22Merge commit 'v2.6.38-rc6' into linaro-2.6.38Nicolas Pitre
2011-02-22ARM: fix build failureUwe Kleine-König
Commit 06824ba (ARM: tlb: delay page freeing for SMP and ARMv7 CPUs) introduced a build failure for builds with CONFIG_SWAP=n: In file included from arch/arm/mm/init.c:27: arch/arm/include/asm/tlb.h: In function 'tlb_flush_mmu': arch/arm/include/asm/tlb.h:101: error: implicit declaration of function 'release_pages' arch/arm/include/asm/tlb.h: In function 'tlb_remove_page': arch/arm/include/asm/tlb.h:165: error: implicit declaration of function 'page_cache_release' Fix that by #including <linux/pagemap.h> in <asm/pgalloc.h> as it's done by x86. Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de> Signed-off-by: Nicolas Pitre <nicolas.pitre@linaro.org>
2011-02-22Merge branch 'p2v' of git://git.linaro.org/people/nico/linux into linaro-2.6.38Nicolas Pitre
2011-02-22Merge commit 'd8d3f25' (misc branch) into linaro-2.6.38Nicolas Pitre
Conflicts: arch/arm/kernel/head.S
2011-02-22Merge commit '3ba6e69' (v6v7 branch) into linaro-2.6.38Nicolas Pitre
Conflicts: arch/arm/mm/Kconfig
2011-02-22Merge remote-tracking branch 'rmk/p2v-stable' into linaro-2.6.38Nicolas Pitre
Conflicts: arch/arm/kernel/module.c
2011-02-22Merge remote-tracking branch 'rmk/devel-stable' into linaro-2.6.38Nicolas Pitre
2011-02-22ARM: 6751/1: vexpress: select applicable errata workarounds in KconfigWill Deacon
The Cortex-A9 tile on the Versatile Express suffers from a number of engineering errata. This patch selects workarounds in the ARCH_VEXPRESS_CA9X4 Kconfig entry so that users don't need to worry about which ones to apply. Reported-by: Ulrich Weigand <Ulrich.Weigand@de.ibm.com> Signed-off-by: Will Deacon <will.deacon@arm.com> Signed-off-by: Nicolas Pitre <nicolas.pitre@linaro.org>
2011-02-21Merge remote-tracking branch 'rmk/fixes' into linaro-2.6.38linaro-linux-2.6.38-upstream-22Feb2011Nicolas Pitre
2011-02-21OMAP: use generic DPI panel driver for overoAndy Doan
Changed to keep consistent with other board files. Based on commit(1e1acca2d11) Signed-off-by: Andy Doan <andy.doan@linaro.org>
2011-02-21OMAP: overo: move to venc platform driverAndy Doan
based on commit(c95a2879d1ee3a0580445e5048dfd7f5353a8435) Signed-off-by: Andy Doan <andy.doan@linaro.org>
2011-02-21OMAP: DSS2: replace platform_device_register with omap_display_initAndy Doan
based on commit(d4cc8c9b1ef3dc48af305175222eea482534d260) This patch replaces platform_add_devices of DSS with omap_display_init(). This moves away registration of DSS from board files into a common place. Signed-off-by: Andy Doan <andy.doan@linaro.org>
2011-02-21OMAP: DSS2: Change driver name to omap_displayAndy Doan
based on commit(7cfd2de91a7ee8b2a24228b9188a53a8a1383812) Change the driver name from omapdss to omap_display as the driver takes care the display devices ie number of panels, type of panels available in the platform. Change the device name in the board files and 2420,2430,3xxx cloc files from omapdss to omap_display to match the driver name. Signed-off-by: Andy Doan <andy.doan@linaro.org>
2011-02-21OMAP: DSS2: Add DSS2 support for OveroSteve Sakoman
based on commit: ef402fe604 from the sakoman tree
2011-02-21OMAP: Add DVFS DocumentationVishwanath BS
Add Documentation for DVFS Framework Signed-off-by: Vishwanath BS <vishwanath.bs@ti.com>
2011-02-21OMAP2PLUS: Enable various options in defconfigThara Gopinath
This patch enables Smartreflex and Cpu Freq in the omap2plus defconfig. Signed-off-by: Thara Gopinath <thara@ti.com>
2011-02-21OMAP2PLUS: Replace voltage values with MacrosVishwanath BS
Currently voltage values on opp tables are hardcoded. As these voltage values are anyway defined in voltage.h as macros, opp table can reuse these values. This will avoid opp table and voltage layer having conflicting values. Signed-off-by: Vishwanath BS <vishwanath.bs@ti.com>
2011-02-21OMAP3: Add voltage dependency table for VDD1.Thara Gopinath
In OMAP3, for perfomrance reasons when VDD1 is at voltage above 1.075V, VDD2 should be at 1.15V for perfomrance reasons. This patch introduce this cross VDD dependency for OMAP3 VDD1. Signed-off-by: Thara Gopinath <thara@ti.com>
2011-02-21OMAP3: Introduce voltage domain info in the hwmod structures.Thara Gopinath
This patch adds voltage domain info in the relevant device hwmod structures so as to enable OMAP3 DVFS support. Signed-off-by: Thara Gopinath <thara@ti.com>
2011-02-21OMAP3: cpufreq driver changes for DVFS supportVishwanath BS
Changes in the omap cpufreq driver for DVFS support. Signed-off-by: Vishwanath BS <vishwanath.bs@ti.com>
2011-02-21OMAP3: Introduce custom set rate and get rate APIs for scalable devicesThara Gopinath
This patch also introduces omap3_mpu_set_rate, omap3_iva_set_rate, omap3_l3_set_rate, omap3_mpu_get_rate, omap3_iva_get_rate, omap3_l3_get_rate as device specific set rate and get rate APIs for OMAP3 mpu, iva and l3_main devices. This patch also calls into omap_device_populate_rate_fns during system init to register various set_rate and get_rate APIs with the omap device layer Signed-off-by: Thara Gopinath <thara@ti.com>
2011-02-21OMAP: Disable Smartreflex across DVFSThara Gopinath
This patch disables smartreflex for a particular voltage domain when the the voltage domain and the devices belonging to it is being scaled and re-enables it back once the scaling is done. Signed-off-by: Thara Gopinath <thara@ti.com> Signed-off-by: Vishwanath BS <vishwanath.bs@ti.com>
2011-02-21OMAP: Introduce device scale implementationVishwanath BS
This patch adds omap_device_scale API which can be used to generic device rate scaling. Based on original patch from Thara. Signed-off-by: Vishwanath BS <vishwanath.bs@ti.com> Cc: Thara Gopinath <thara@ti.com>
2011-02-21OMAP: Introduce dependent voltage domain supportVishwanath BS
There could be dependencies between various voltage domains for maintaining system performance or hardware limitation reasons like VDD<X> should be at voltage v1 when VDD<Y> is at voltage v2. This patch introduce dependent vdd information structures in the voltage layer which can be used to populate these dependencies for a voltage domain. This patch also adds support to scale the dependent vdd and the scalable devices belonging to it during the scaling of a main vdd through omap_voltage_scale. As part of this, some of the voltage layer structure definitions are moved from voltage.c to voltage.h as it needs to be used in the dvfs layer for dependency voltage handling. Based on original patch from Thara. Signed-off-by: Vishwanath BS <vishwanath.bs@ti.com> Cc: Thara Gopinath <thara@ti.com>
2011-02-21OMAP: Implement Basic DVFSVishwanath BS
This patch introduces an API to perform DVFS for a given voltage domain. It takes omap_vdd_dvfs_info pointer as input parameter, computes the highest requested voltage for that vdd and scales all the devices in that vdd to the requested frequency along with voltage scaling. Based on original patch from Thara. Signed-off-by: Vishwanath BS <vishwanath.bs@ti.com> Cc: Thara Gopinath <thara@ti.com>
2011-02-21OMAP: Introduce device specific set rate and get rate in omap_device structureThara Gopinath
This patch extends the omap_device structure to contain pointers to scale the operating rate of the device and to retrieve the operating rate of the device. This patch also adds the three new APIs in the omap device layer namely omap_device_set_rate that can be called to set a new operating rate for a device, omap_device_get_rate that can be called to retrieve the operating frequency for a device and omap_device_register_dvfs_callbacks to register the device specific set_rate and get_rate functions. The omap_device_set_rate and omap_device_get_rate does some routine error checks and finally calls into the device specific set_rate and get_rate APIs populated through omap_device_populate_rate_fns. Signed-off-by: Thara Gopinath <thara@ti.com> Signed-off-by: Vishwanath BS <vishwanath.bs@ti.com>
2011-02-21OMAP: Introduce accessory APIs for DVFSVishwanath BS
This patch introduces accessory APIs for DVFS. Data structures added: 1. omap_dev_user_list: This structure maintains list of frequency requests per device basis. When a device needs to be scaled to a particular frequency, This list is searched to find the maximum request for a given device. If noone has placed any request, device frequency is obtained from device opp table. 2. omap_vdd_dev_list: This strcucture stores device list per vdd basis. Whenever a device is registered with a vdd, it is added to this list. 3. omap_vdd_user_list: User list of devices associated with each voltage domain instance. The user list is implemented using plist structure with priority node populated with the voltage values. 4. omap_vdd_dvfs_info: This structure is used to abstract DVFS related information per VDD basis. It holds pointer to corresponding vdd's voltagedomain instance and pointer to user list. Following APIs have been added to operate on above data structures: 1. omap_dvfs_add_vdd_user - API to add a user into omap_vdd_user_list 2. omap_vdd_user_list - API to remove a user from omap_vdd_user_list 3. omap_dvfs_register_device - API to register a device with vdd 4. omap_dvfs_add_freq_request - API to add a frequency request into omap_dev_user_list 5. omap_dvfs_remove_freq_request - API to remove a frequency request from omap_dev_user_list 6. omap_dvfs_find_voltage - API to find the opp corresponding to given voltage DVFS layer is initialized and basic data structures are allocated and initialized as part of this. This patch is based on Thara's previous DVFS implementation, but with major rework. Signed-off-by: Vishwanath BS <vishwanath.bs@ti.com> Cc: Thara Gopinath <thara@ti.com>
2011-02-21OMAP3: PM: Set/clear T2 bit for Smartreflex on TWLThara Gopinath
Voltage control on TWL can be done using VMODE/I2C1/I2C_SR. Since almost all platforms use I2C_SR on omap3, omap3_twl_init by default expects that OMAP's I2C_SR is plugged in to TWL's I2C and calls omap3_twl_set_sr_bit. On platforms where I2C_SR is not connected, the board files are expected to call omap3_twl_set_sr_bit(false) to ensure that I2C_SR path is not set for voltage control and prevent the default behavior of omap3_twl_init. Signed-off-by: Nishanth Menon <nm@ti.com> Signed-off-by: Thara Gopinath <thara@ti.com> Signed-off-by: Shweta Gulati <shweta.gulati@ti.com>
2011-02-21ARM: S5P: Fix end address in memory resource information for UART devicesThomas Abraham
For S5P platforms, the end address in memory resource information for UART devices is one byte more than the intended value. Fix this by reducing the end address by one byte. Signed-off-by: Thomas Abraham <thomas.abraham@linaro.org>
2011-02-21cpufreq: Add documentation for sampling_down_factorVishwanath BS
Update cpufreq governor documentation for sampling_down_factor tunable parameter. Signed-off-by: Vishwanath BS <vishwanath.bs@ti.com> Signed-off-by: Nicolas Pitre <nicolas.pitre@linaro.org>
2011-02-21mach-ux500: fix inverted SD-card GPIO pinPhilippe Langlais
The levelshifter pins were set to inverted values, fix this up. Signed-off-by: Philippe Langlais <philippe.langlais@stericsson.com> Signed-off-by: Linus Walleij <linus.walleij@stericsson.com> (cherry picked from commit a7abcd3e4dc34e31a8981494c0a83ef9bd2b9934)
2011-02-21mach-ux500: set sd/mmc clock rate to 100MHzPhilippe Langlais
The clock speed for the SD/MMC clock was incorrect, rectify it. Signed-off-by: Philippe Langlais <philippe.langlais@stericsson.com> Signed-off-by: Linus Walleij <linus.walleij@stericsson.com> (cherry picked from commit fabb07c7f171dd948064ae984515de139ad7d1e6)
2011-02-21Set the u8500 to use the nomadik mach idLinus Walleij
Signed-off-by: Nicolas Pitre <nicolas.pitre@linaro.org>
2011-02-21ARM: iMX51 BBG: add clock debug informationYong Shen
Expose clock debug information to debugfs, which makes it easier for clock system debug by using tools like powerdebug developed by Linaro power management group. For long term, this can go into common clock framework, but so far it depends on the process of common clk API development. Once the common clk API is ready in upstream, the clock debug information will be based on it too. The implementation based on common clk API had also been finished and reviewed with Jeremy. Signed-off-by: Yong Shen <yong.shen@linaro.org> Signed-off-by: Nicolas Pitre <nicolas.pitre@linaro.org>
2011-02-21Linux 2.6.38-rc6v2.6.38-rc6Linus Torvalds
2011-02-21Merge branch 'for-linus' of ↵Linus Torvalds
git://git.kernel.org/pub/scm/linux/kernel/git/ecryptfs/ecryptfs-2.6 * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/ecryptfs/ecryptfs-2.6: eCryptfs: Copy up lower inode attrs in getattr ecryptfs: read on a directory should return EISDIR if not supported eCryptfs: Handle NULL nameidata pointers eCryptfs: Revert "dont call lookup_one_len to avoid NULL nameidata"
2011-02-21drm/i915: Do not handle backlight combination mode speciallyIndan Zupancic
The current code does not follow Intel documentation: It misses some things and does other, undocumented things. This causes wrong backlight values in certain conditions. Instead of adding tricky code handling badly documented and rare corner cases, don't handle combination mode specially at all. This way PCI_LBPC is never touched and weird things shouldn't happen. If combination mode is enabled, then the only downside is that changing the brightness has a greater granularity (the LBPC value), but LBPC is at most 254 and the maximum is in the thousands, so this is no real functional loss. A potential problem with not handling combined mode is that a brightness of max * PCI_LBPC is not bright enough. However, this is very unlikely because from the documentation LBPC seems to act as a scaling factor and doesn't look like it's supposed to be changed after boot. The value at boot should always result in a bright enough screen. IMPORTANT: However, although usually the above is true, it may not be when people ran an older (2.6.37) kernel which messed up the LBPC register, and they are unlucky enough to have a BIOS that saves and restores the LBPC value. Then a good kernel may seem to not work: Max brightness isn't bright enough. If this happens people should boot back into the old kernel, set brightness to the maximum, and then reboot. After that everything should be fine. For more information see the below links. This fixes bugs: http://bugzilla.kernel.org/show_bug.cgi?id=23472 http://bugzilla.kernel.org/show_bug.cgi?id=25072 Signed-off-by: Indan Zupancic <indan@nul.nu> Tested-by: Alex Riesen <raa.lkml@gmail.com> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2011-02-21module: explicitly align module_version_attribute structureDmitry Torokhov
We force particular alignment when we generate attribute structures when generation MODULE_VERSION() data and we need to make sure that this alignment is followed when we iterate over these structures, otherwise we may crash on platforms whose natural alignment is not sizeof(void *), such as m68k. Reported-by: Geert Uytterhoeven <geert@linux-m68k.org> Signed-off-by: Dmitry Torokhov <dtor@vmware.com> [ There are more issues here, but the fixes are incredibly ugly - Linus ] Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>