aboutsummaryrefslogtreecommitdiff
path: root/arch/arm/mach-omap2
AgeCommit message (Collapse)Author
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-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: 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 remote-tracking branch 'rmk/p2v-stable' into linaro-2.6.38Nicolas Pitre
Conflicts: arch/arm/kernel/module.c
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-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: 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 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-17ARM: 6651/1: omap: Fix DEBUG_LL code for p2v changesTony Lindgren
These are needed for CONFIG_ARM_PATCH_PHYS_VIRT to work. Signed-off-by: Tony Lindgren <tony@atomide.com> Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2011-02-09OMAP4: PandaBoard: Adding DVI supportRaghuveer Murthy
Adding DVI support to OMAP4 PandaBoard. PandaBoard uses TFP410 DVI Framer chip http://focus.ti.com/lit/ds/symlink/tfp410.pdf The TFP410 gets its power enable and display data over GPIO lines muxed in from OMAP4430. PandaBoard supports other LCD displays through expansion connectors, following board rework. This will disable the DVI interface. However, the existing mux settings remain the same PandaBoard additionally supports display over HDMI interface. It is mutually exclusive to display over DVI. Hence the mux settings need to be configured seperately, as and when HDMI is enabled Also, I2C3 bus used for reading EDID data from DVI Monitors is registered here. Since the design is similar to BeagleBoard, the code for the same is taken from the kernel.org commit e3333f48dd5cb21 (omap: Adding beagle i2c eeprom driver to read EDID) Signed-off-by: Raghuveer Murthy <raghuveer.murthy@ti.com>
2011-02-09OMAP4: DSS2: Add hwmod device names for OMAP4.Mayuresh Janorkar
Add hwmod device names for OMAP4; this enables device build for omap4 dss hwmod IPs. Signed-off-by: Sumit Semwal <sumit.semwal@ti.com> Signed-off-by: Mayuresh Janorkar <mayur@ti.com>
2011-02-09OMAP4: hwmod data: add DSS DISPC DSI1,2 RFBI HDMI VENCBenoit Cousson
Add dss, dispc, dsi1, dsi2, hdmi, rfbi and venc hwmods. In OMAP4 there are severals IPs that can be reached by differents interconnect paths depending of the access initiator (MPU vs. SDMA). In the case of the DSS, both L3 direct path and L4 CFG path can be used to access all the DSS IPs. The two ocp_ip already exists to support the two address spaces. +------------+-- L3_MAIN --+ MPU IP | | +-- L4_CFG --+ L3 main address range is specified first, since it is used by default. dss is also considered as an IP as dispc, rfbi, and named as dss_core. Signed-off-by: Benoit Cousson <b-cousson@ti.com> Signed-off-by: Mayuresh Janorkar <mayur@ti.com> Signed-off-by: Senthilvadivu Guruswamy <svadivu@ti.com> Signed-off-by: Sumit Semwal <sumit.semwal@ti.com>
2011-02-09OMAP4: DSS2: clocks: Add ick as dummy clockSumit Semwal
DSS code uses ick as one of the clocks in clk_get/clk_put. OMAP4 clock database doesn't have ick for DSS, so adding ick as dummy clock. This is needed for backward compatibility with OMAP2/3. Once pm_runtime* APIs get introduced in DSS, this will be revisited. Signed-off-by: Sumit Semwal <sumit.semwal@ti.com>
2011-02-09OMAP2PLUS: clocks: Align DSS clock names and rolesSumit Semwal
Currently, clock database has <dev, clock-name> tuples for DSS2. Because of this, the clock names are different across different OMAP platforms. This patch aligns the DSS2 clock names and roles across OMAP 2420, 2430, 3xxx, 44xx platforms in the clock databases, hwmod databases for opt-clocks, and DSS clock handling. This ensures that clk_get/put/enable/disable APIs in DSS can use uniform role names. Signed-off-by: Sumit Semwal <sumit.semwal@ti.com>
2011-02-09OMAP2, 3: DSS2: DSI: create platform_driver, move init, exit to driverSenthilvadivu Guruswamy
Hwmod adaptation design requires each of the DSS HW IP to be a platform driver. So a platform_driver for DSI is created and init exit methods are moved from core.c to its driver probe,remove. pdev member has to be maintained by its own drivers. Also, vdds_dsi regulator handling is copied to dsi.c, since vdds_dsi regulator is needed by dpi_init() too. Board files are updated accordingly to add 2 instances of vdds_dsi regulator. DSI platform driver is registered from inside omap_dss_probe, in the order desired. Reviewed-by: Kevin Hilman <khilman@ti.com> Tested-by: Kevin Hilman <khilman@ti.com> Signed-off-by: Senthilvadivu Guruswamy <svadivu@ti.com> Signed-off-by: Sumit Semwal <sumit.semwal@ti.com>
2011-02-09OMAP2, 3: DSS2: VENC: create platform_driver, move init, exit to driverSenthilvadivu Guruswamy
Hwmod adaptation design requires each of the DSS HW IP to be a platform driver. So a platform_driver for VENC is created and init exit methods are moved from core.c to its driver probe,remove. pdev member has to be maintained by its own drivers. Also, venc_vdda_dac reading is moved to venc.c. VENC platform driver is registered from inside omap_dss_probe, in the order desired. Reviewed-by: Kevin Hilman <khilman@ti.com> Tested-by: Kevin Hilman <khilman@ti.com> Signed-off-by: Senthilvadivu Guruswamy <svadivu@ti.com> Signed-off-by: Sumit Semwal <sumit.semwal@ti.com>
2011-02-09OMAP2, 3: DSS2: Move clocks from core driver to dss driverSenthilvadivu Guruswamy
All clock management is moved to dss platform driver. clk_get/put APIs use dss device instead of core platform device. Hwmod adaptation design requires each of the DSS HW IP to be a platform driver. So the device name is changed from omap_display to omap_dss in 2420, 2430, 3xxx clock database files. Now the core driver "omap_display" only takes care of panel registration with the custom bus. core driver also uses the clk_enable() / clk_disable() APIs exposed by DSS for clock management. DSS driver would do clock management of clocks needed by DISPC, RFBI, DSI, VENC TODO: The clock content would be adapted to omap_hwmod in a seperate series. Acked-by: Paul Walmsley <paul@pwsan.com> Reviewed-by: Kevin Hilman <khilman@ti.com> Tested-by: Kevin Hilman <khilman@ti.com> Signed-off-by: Senthilvadivu Guruswamy <svadivu@ti.com> Signed-off-by: Sumit Semwal <sumit.semwal@ti.com>
2011-02-09OMAP2,3: DSS2: Build omap_device for each DSS HWIPSenthilvadivu Guruswamy
Looks up the hwmod database for each of the given DSS HW IP and builds omap_device which inturn does the platform device register for each of DSS HW IP Reviewed-by: Kevin Hilman <khilman@ti.com> Tested-by: Kevin Hilman <khilman@ti.com> Signed-off-by: Senthilvadivu Guruswamy <svadivu@ti.com> Signed-off-by: Sumit Semwal <sumit.semwal@ti.com>
2011-02-09OMAP2, 3: DSS2: board files: replace platform_device_register with ↵Senthilvadivu Guruswamy
omap_display_init() This patch updated board files to replace platform_device_register or platform_add_devices of DSS with omap_display_init(). This moves away registration of DSS from board files into a common place. Reviewed-by: Kevin Hilman <khilman@ti.com> Tested-by: Kevin Hilman <khilman@ti.com> Signed-off-by: Sumit Semwal <sumit.semwal@ti.com> Signed-off-by: Senthilvadivu Guruswamy <svadivu@ti.com>
2011-02-09OMAP2, 3: DSS2: Create new file display.c for central dss driver registration.Sumit Semwal
A new file display.c is introduced for display driver init, which adds a function omap_display_init to do the DSS driver registration. This is the first step in moving away registration of DSS from board files into a common place. Reviewed-by: Kevin Hilman <khilman@ti.com> Tested-by: Kevin Hilman <khilman@ti.com> Signed-off-by: Senthilvadivu Guruswamy <svadivu@ti.com> Signed-off-by: Sumit Semwal <sumit.semwal@ti.com>
2011-02-09OMAP2,3 DSS2 Use Regulator init with driver nameSenthilvadivu Guruswamy
Use driver name in regulator inits needed for display instead of using device structure name. Reviewed-by: Kevin Hilman <khilman@ti.com> Tested-by: Kevin Hilman <khilman@ti.com> Signed-off-by: Senthilvadivu Guruswamy <svadivu@ti.com> Signed-off-by: Sumit Semwal <sumit.semwal@ti.com>
2011-02-09OMAP2,3 DSS2 Change driver name to omap_displaySenthilvadivu Guruswamy
Change the driver name from omapdss to omap_display as the driver takes care of 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 clock files from omapdss to omap_display to match the driver name. Signed-off-by: Sumit Semwal <sumit.semwal@ti.com> Acked-by: Paul Walmsley <paul@pwsan.com> for: The clkdev changes in clock2420_data.c, clock2430_data.c, clock3xxx_data.c Reviewed-by: Kevin Hilman <khilman@ti.com> Tested-by: Kevin Hilman <khilman@ti.com> Signed-off-by: Senthilvadivu Guruswamy <svadivu@ti.com>
2011-02-09OMAP3: hwmod data: add DSS DISPC RFBI DSI VENCSenthilvadivu Guruswamy
Hwmod needs database of all IPs in a system. This patch generates the hwmod database for Display Sub System applicable for OMAP3430 and OMAP36xx. DSS is also considered as an IP as DISPC, RFBI and named as dss_core. For all the IP modules in DSS, same clock is needed for enabling. Hwmod sees DSS IPs as independent IPs, so same clock has to be repeated for .main_clk in each IP. This patch defines separate hwmod databases for OMAP3430ES1 and (OMAP3430ES2 and OMAP36xx) as OMAP3430ES1 does not have IDLEST bit to poll on for dss IP, and also the firewall regions are different between 3430es1 and later. Reviewed-by: Kevin Hilman <khilman@ti.com> Tested-by: Kevin Hilman <khilman@ti.com> Signed-off-by: Sumit Semwal <sumit.semwal@ti.com> Signed-off-by: Senthilvadivu Guruswamy <svadivu@ti.com>
2011-02-09OMAP2430: hwmod data: add DSS DISPC RFBI VENCSenthilvadivu Guruswamy
Hwmod needs database of all IPs in a system. This patch generates the hwmod database for OMAP2430 Display Sub System. Since DSS is also considered as an IP as DISPC, RFBI, name it as dss_core. Acked-by: Benoit Cousson <b-cousson@ti.com> Reviewed-by: Kevin Hilman <khilman@ti.com> Tested-by: Kevin Hilman <khilman@ti.com> Signed-off-by: Sumit Semwal <sumit.semwal@ti.com> Signed-off-by: Senthilvadivu Guruswamy <svadivu@ti.com>
2011-02-09OMAP2420: hwmod data: add DSS DISPC RFBI VENCSenthilvadivu Guruswamy
Hwmod needs database of all IPs in a system. This patch generates the hwmod database for OMAP2420 Display Sub System,. Since DSS is also considered as an IP as DISPC, RFBI, name it as dss_core. Acked-by: Benoit Cousson <b-cousson@ti.com> Reviewed-by: Kevin Hilman <khilman@ti.com> Tested-by: Kevin Hilman <khilman@ti.com> Signed-off-by: Sumit Semwal <sumit.semwal@ti.com> Signed-off-by: Senthilvadivu Guruswamy <svadivu@ti.com>
2011-02-02arm: omap4: panda: remove usb_nop_xceiv_register(v1)Ming Lei
Panda uses both twl6030 otg phy(vbus, id) and internal phy(data lines, DP/DM), so removes usb_nop_xceiv_register to make twl6030 otg driver working since current otg code only supports one global transceiver. Otherwise, musb doesn't work without the remove. Reviewd-by: Felipe Balbi <balbi@ti.com> Signed-off-by: Ming Lei <tom.leiming@gmail.com> Signed-off-by: Tony Lindgren <tony@atomide.com>
2011-02-01OMAP3: Devkit8000: Change lcd power pinThomas Weber
This patch fixes a wrongly used lcd enable pin. The Devkit8000 uses twl4030_ledA configured as output gpio only for the lcd enable line. twl4030_gpio.1 is used through the generic gpio functions while ledA is used via low level twl4030 calls. This patch removes the low level calls and use the generic gpio functions for initialization and use of ledA. This patch also fixes a bug where the lcd would not power down when blanking. Further this patch fixes an indentation issue. The comment line uses eight whitespace and is replaced with a hard tab. gpio_request + gpio_direction_output are replaced with gpio_request_one. The return value of gpio_request_one is used to set the value of the gpio to -EINVAL when unsuccessful, so that gpio_is_valid can detect the unsuccessful request. But already successful requested gpios are not freed. Reported-by: Daniel Morsing <daniel.morsing@gmail.com> Signed-off-by: Thomas Weber <weber@corscience.de> Signed-off-by: Tony Lindgren <tony@atomide.com>
2011-02-01arm: mach-omap2: mux: free allocated memory on error exitAaro Koskinen
Free allocated memory on error exit. Signed-off-by: Aaro Koskinen <aaro.koskinen@nokia.com> Signed-off-by: Tony Lindgren <tony@atomide.com>
2011-02-01arm: mach-omap2: board-rm680: fix rm680_vemmc regulator constraintsAaro Koskinen
With the commit 757902513019e6ee469791ff76f954b19ca8d036 (regulator: Factor out voltage set operation into a separate function) fixed voltage regulator setup will fail if there are voltage constraints defined. This made MMC unusable on this board. Fix by just deleting those redundant constraints. Signed-off-by: Aaro Koskinen <aaro.koskinen@nokia.com> Reviewed-by: Jarkko Nikula <jhnikula@gmail.com> [tony@atomide.com: updated comments] Signed-off-by: Tony Lindgren <tony@atomide.com>
2011-01-31Merge branch 'for_2.6.38/pm-fixes' of ↵Tony Lindgren
ssh://master.kernel.org/pub/scm/linux/kernel/git/khilman/linux-omap-pm into devel-fixes
2011-01-31OMAP: PM: SmartReflex: Fix possible null pointer read accessStefan Weil
These errors were found by cppcheck: arch/arm/mach-omap2/smartreflex.c:784: error: Possible null pointer dereference: sr_info arch/arm/mach-omap2/smartreflex.c:799: error: Possible null pointer dereference: sr_info Both conditional statements are executed when sr_info == NULL, so accessing sr_info->voltdm would fail. Cc: Russell King <linux@arm.linux.org.uk> Cc: linux-omap@vger.kernel.org Cc: linux-arm-kernel@lists.infradead.org Cc: linux-kernel@vger.kernel.org Signed-off-by: Stefan Weil <weil@mail.berlios.de> Signed-off-by: Kevin Hilman <khilman@ti.com>
2011-01-31OMAP: PM: SmartReflex: Fix possible memory leakStefan Weil
sr_info was allocated and needs a kfree before returning. This error was reported by cppcheck: arch/arm/mach-omap2/smartreflex.c:837: error: Memory leak: sr_info To: Tony Lindgren <tony@atomide.com> Cc: Russell King <linux@arm.linux.org.uk> Cc: linux-omap@vger.kernel.org Cc: linux-arm-kernel@lists.infradead.org Cc: linux-kernel@vger.kernel.org Signed-off-by: Stefan Weil <weil@mail.berlios.de> Acked-by: Shweta Gulati <shweta.gulati@ti.com> Signed-off-by: Kevin Hilman <khilman@ti.com>
2011-01-31arm: mach-omap2: voltage: debugfs: fix memory leakAaro Koskinen
The temporary string holding the directory name to be created should be released. Signed-off-by: Aaro Koskinen <aaro.koskinen@nokia.com> Signed-off-by: Kevin Hilman <khilman@ti.com>
2011-01-27arch/arm/mach-omap2/dma.c: Convert IS_ERR result to PTR_ERRJulia Lawall
This code elsewhere returns a negative constant to an indicate an error, while IS_ERR returns the result of a >= operation. The semantic patch that fixes this problem is as follows: (http://coccinelle.lip6.fr/) // <smpl> @@ expression x; @@ if (...) { ... - return IS_ERR(x); + return PTR_ERR(x); } // </smpl> Signed-off-by: Julia Lawall <julia@diku.dk> Acked-by: Jarkko Nikula <jhnikula@gmail.com> Signed-off-by: Tony Lindgren <tony@atomide.com>
2011-01-27arm: omap2: mux: fix compile warningFelipe Balbi
Commit 8419fdbaf2118a0a169441be82f09f7be93a5ca1 (omap2+: Add omap_mux_get_by_name) introduced the following compile warning: arch/arm/mach-omap2/mux.c: In function '_omap_mux_get_by_name': arch/arm/mach-omap2/mux.c:163:17: warning: 'found_mode' may be used uninitialized in this function Signed-off-by: Felipe Balbi <balbi@ti.com> [tony@atomide.com: updated comments] Signed-off-by: Tony Lindgren <tony@atomide.com>