aboutsummaryrefslogtreecommitdiff
AgeCommit message (Collapse)AuthorFilesLines
2010-08-11s3c-fb: fix various null references on framebuffer memory alloc failurePawel Osciak1-3/+5
The following problems were found in the above situation: sfb->windows[win] was being assigned at the end of s3c_fb_probe_win only. This resulted in passing a NULL to s3c_fb_release_win if probe_win returned early and a memory leak. dma_free_writecombine does not allow its third argument to be NULL. fb_dealloc_cmap does not verify whether its argument is not NULL. Signed-off-by: Pawel Osciak <[email protected]> Signed-off-by: Kyungmin Park <[email protected]> Cc: InKi Dae <[email protected]> Cc: Ben Dooks <[email protected]> Cc: Marek Szyprowski <[email protected]> Signed-off-by: Andrew Morton <[email protected]> Signed-off-by: Linus Torvalds <[email protected]>
2010-08-11s3c-fb: integrate palette setup code into main driverBen Dooks2-35/+32
Remove the palette setup code from the header files and put it into the main driver. Signed-off-by: Ben Dooks <[email protected]> Signed-off-by: Pawel Osciak <[email protected]> Cc: InKi Dae <[email protected]> Cc: KyungMin Park <kyungmin.park.samsung.com> Cc: Marek Szyprowski <[email protected]> Signed-off-by: Andrew Morton <[email protected]> Signed-off-by: Linus Torvalds <[email protected]>
2010-08-11s3c-fb: udpate to support s3c2416/s3c2443 style hardwareBen Dooks3-38/+136
Update the variant and window variant structures with the necessary changes to support the older style of hardware where these are not in the same place. Add the support for the s3c2443/s3c2416 hardware by using the platform-device s3c2443 to cover both, and add the initialisation data for these. Also change to including just the v4 header files for the moment until the last of the merging of these is sorted out. Signed-off-by: Ben Dooks <[email protected]> Signed-off-by: Pawel Osciak <[email protected]> Cc: InKi Dae <[email protected]> Cc: KyungMin Park <kyungmin.park.samsung.com> Cc: Marek Szyprowski <[email protected]> Signed-off-by: Andrew Morton <[email protected]> Signed-off-by: Linus Torvalds <[email protected]>
2010-08-11s3c-fb: initial move to unifying the header filesBen Dooks4-118/+180
Remove the various header files that configure this driver and use the platform device name to select the correct configuration at probe time. Currently this does not remove the header files, only updates the driver and the relevant platform files. Signed-off-by: Ben Dooks <[email protected]> Signed-off-by: Pawel Osciak <[email protected]> Cc: InKi Dae <[email protected]> Cc: KyungMin Park <kyungmin.park.samsung.com> Cc: Marek Szyprowski <[email protected]> Signed-off-by: Andrew Morton <[email protected]> Signed-off-by: Linus Torvalds <[email protected]>
2010-08-11s3c-fb: only init window colour key controls for windows with blendingBen Dooks1-3/+11
The driver clears all windows, but also sets the windows' colour key controls at the same time. However, the last window does not have these registers as it is always blended into the previous window. Move the colour key initialisation into the probe, and run it for only nr_win-1 windows. Signed-off-by: Ben Dooks <[email protected]> Signed-off-by: Pawel Osciak <[email protected]> Cc: InKi Dae <[email protected]> Cc: KyungMin Park <kyungmin.park.samsung.com> Cc: Marek Szyprowski <[email protected]> Signed-off-by: Andrew Morton <[email protected]> Signed-off-by: Linus Torvalds <[email protected]>
2010-08-11s3c-fb: fix distortedness situation for the mode more then 24bppInKi Dae2-0/+2
It has been working fine at 16bpp but in case of pixel format more then 24bpp it would occur distortedness situation on that mode. so this patch set the word swap control bit of WINCONx to 1 as default value. but it should be set to 0 in case that each ENLOCAL bit of WINCON0 ~ 2 registers is enabled. this issue would be solved with local path feature soon. Signed-off-by: InKi Dae <[email protected]> Reviewed-by: KyungMin Park <kyungmin.park.samsung.com> Signed-off-by: Ben Dooks <[email protected]> Signed-off-by: Pawel Osciak <[email protected]> Cc: Marek Szyprowski <[email protected]> Signed-off-by: Andrew Morton <[email protected]> Signed-off-by: Linus Torvalds <[email protected]>
2010-08-11s3c-fb: add default window feature.InKi Dae2-3/+6
s5pv210 has five window layers (window0 ~ 4), among them, window0 ~ 2 could be used for local path with fimc(capture device) and fimd writeback feature so this patch makes default window layer for UI to be set at machine code. Signed-off-by: InKi Dae <[email protected]> Reviewed-by: KyungMin Park <kyungmin.park.samsung.com> Signed-off-by: Ben Dooks <[email protected]> Signed-off-by: Pawel Osciak <[email protected]> Cc: Marek Szyprowski <[email protected]> Signed-off-by: Andrew Morton <[email protected]> Signed-off-by: Linus Torvalds <[email protected]>
2010-08-11s3c-fb: change to depending on CONFIG_S3C_FB_DEVBen Dooks1-1/+1
As suggested by Marek Szyprowski, we should make the driver depend on the configuration currently being used to build the platform device into the kernel. Signed-off-by: Ben Dooks <[email protected]> Signed-off-by: Pawel Osciak <[email protected]> Cc: InKi Dae <[email protected]> Cc: KyungMin Park <kyungmin.park.samsung.com> Cc: Marek Szyprowski <[email protected]> Signed-off-by: Andrew Morton <[email protected]> Signed-off-by: Linus Torvalds <[email protected]>
2010-08-11drivers/video/fbmem.c: simplify strlen()==0 check in fb_get_options()Denys Vlasenko1-3/+2
Replaced !strlen(str) check with !str[0]. Removed the variable which was used solely to store strlen result. Signed-off-by: Denys Vlasenko <[email protected]> Signed-off-by: Andrew Morton <[email protected]> Signed-off-by: Linus Torvalds <[email protected]>
2010-08-11fbcon: uninline four foo_update_attr() functionsDenys Vlasenko4-4/+4
This patch uninlines four similar functions, foo_update_attr(), in four fbcon-related files. These functions contain loops, two of theam have _nested_ loops, and they have more than one callsite each. I think they should not be inlined. Signed-off-by: Denys Vlasenko <[email protected]> Signed-off-by: Andrew Morton <[email protected]> Signed-off-by: Linus Torvalds <[email protected]>
2010-08-11fbcon: uninline large static function get_color()Denys Vlasenko1-1/+1
This function's body is good two screenfuls and it has six callsites. No apparent reason why it is marked inline. Signed-off-by: Denys Vlasenko <[email protected]> Signed-off-by: Andrew Morton <[email protected]> Signed-off-by: Linus Torvalds <[email protected]>
2010-08-11fbdev: efifb: section fixesHenrik Kretzschmar1-4/+4
Remove 43 section mismatches by moving the two structures efifb_defined and efifb_fix from .init.data to .devinit.data. Also the two structure arrays dmi_system_table[] and dmi_list[] have been moved from .data to .init.rodata and .init.data, which saves, if built-in, some space. On x86_64 'size -A' showed that these sections changed size: efifb.o: section size-old size-new .data 1200 688 .init.data 7840 512 .init.rodata 0 7568 .devinit.data 0 256 Total 11927 11911 Signed-off-by: Henrik Kretzschmar <[email protected]> Cc: Peter Jones <[email protected]> Signed-off-by: Andrew Morton <[email protected]> Signed-off-by: Linus Torvalds <[email protected]>
2010-08-11gpio: sx150x: add Semtech I2C sx150x gpio expander driverGregory Bean4-0/+735
Add support for Semtech SX150-series I2C GPIO expanders. Compatible models include: 8 bits: sx1508q 16 bits: sx1509q Signed-off-by: Gregory Bean <[email protected]> Cc: David Brownell <[email protected]> Cc: Jean Delvare <[email protected]> Cc: Trilok Soni <[email protected]> Signed-off-by: Andrew Morton <[email protected]> Signed-off-by: Linus Torvalds <[email protected]>
2010-08-11gpiolib: allow nested threaded irqs for poll(2)Daniel Gl?ckner1-2/+2
The pca953x driver requires the use of threaded irqs as its irq demultiplexer can sleep. Our irq handler can be called from any context, so use request_any_context_irq to allow threaded irqs as well. Signed-off-by: Daniel Gl?ckner <[email protected]> Reported-by: Ian Jeffray <[email protected]> Cc: David Brownell <[email protected]> Signed-off-by: Andrew Morton <[email protected]> Signed-off-by: Linus Torvalds <[email protected]>
2010-08-11gpiolib: get rid of struct poll_desc and workletDaniel Gl?ckner1-53/+27
As sysfs_notify_dirent has been made irq safe, there is no reason to not call it directly from irq. With the work_struct removed, the remaining element in poll_desc is a sysfs_dirent pointer which may not be NULL. We can therefore store it directly in the idr and pass it as context to the irq handler. Most part of the patch deals with renaming defines and variables to reflect their new use without functional change. I also took the opportunity to initialize the idr statically. Signed-off-by: Daniel Gl?ckner <[email protected]> Cc: David Brownell <[email protected]> Signed-off-by: Andrew Morton <[email protected]> Signed-off-by: Linus Torvalds <[email protected]>
2010-08-11gpiolib: decouple might_sleep_if() from DEBUGDavid Brownell2-12/+35
Be more consistent about runtime programming interface abuse warnings, which can reduce some confusion and trigger bugfixes. Based on an observation and patch from Jani Nikula. Also update doc to highlight some sleeping-call issues and to match some recent changes. Signed-off-by: David Brownell <[email protected]> Cc: Jani Nikula <[email protected]> Cc: "Ryan Mallon" <[email protected]> Signed-off-by: Andrew Morton <[email protected]> Signed-off-by: Linus Torvalds <[email protected]>
2010-08-11pcf857x: support working w/o platform dataDmitry Eremin-Solenikov1-5/+4
Provide sane defaults for pcf857x, so the driver can be used w/o providing platform data (and thus can be simply bound via OF tree). Signed-off-by: Dmitry Eremin-Solenikov <[email protected]> Cc: Jean Delvare <[email protected]> Cc: David Brownell <[email protected]> Cc: Grant Likely <[email protected]> Signed-off-by: Andrew Morton <[email protected]> Signed-off-by: Linus Torvalds <[email protected]>
2010-08-11gpio: max730x: make pullups configurable via platformdataMarc Kleine-Budde2-7/+23
The gpios on the max730x chips have support for internal pullups while in input mode. This patch adds support for configuring these pullups via platform data. A new member ("input_pullup_active") to the platform data struct is introduced. A set bit in this variable activates the pullups while the respective port is in input mode. This is a compatible enhancement since unset bits lead to disables pullups which was the default in the original driver. _Note_: the 4 lowest bits in "input_pullup_active" are unused because the first 4 ports of the controller are not used, too. Signed-off-by: Marc Kleine-Budde <[email protected]> Reviewed-by: Wolfram Sang <[email protected]> Cc: David Brownell <[email protected]> Signed-off-by: Andrew Morton <[email protected]> Signed-off-by: Linus Torvalds <[email protected]>
2010-08-11rtc: rp5c01: add NVRAM supportGeert Uytterhoeven1-0/+89
The Ricoh RP5C01 RTC contains 26 x 4 bits of NVRAM. Provide access to it via a sysfs "nvram" attribute file. Signed-off-by: Geert Uytterhoeven <[email protected]> Cc: Wan ZongShun <[email protected]> Cc: Alessandro Zummo <[email protected]> Signed-off-by: Andrew Morton <[email protected]> Signed-off-by: Linus Torvalds <[email protected]>
2010-08-11drivers/rtc: remove unneeded ifdef CONFIG_PMChristian Dietrich1-6/+0
Because CONFIG_PM is a precondition to CONFIG_ACPI, the ifdef CONFIG_PM within ifdef CONFIG_ACPI is redundant. Signed-off-by: Christian Dietrich <[email protected]> Acked-by: Wan ZongShun <[email protected]> Cc: Alessandro Zummo <[email protected]> Signed-off-by: Andrew Morton <[email protected]> Signed-off-by: Linus Torvalds <[email protected]>
2010-08-11rtc-isl12022: properly handle military hour formatRoman Fietze1-1/+1
Mask out PM flag when reading the hour, always set MIL bit when writing the hour. Signed-off-by: Roman Fietze <[email protected]> Acked-by: Wan ZongShun <[email protected]> Cc: Alessandro Zummo <[email protected]> Signed-off-by: Andrew Morton <[email protected]> Signed-off-by: Linus Torvalds <[email protected]>
2010-08-11rtc: add support for DS3232 RTCRoy Zang3-0/+337
Add a driver for the DS3232 RTC chip via the I2C bus. Alarms are not supported in this version of the driver. [[email protected]: fix Kconfig help text] Signed-off-by: Mingkai Hu <[email protected]> Signed-off-by: Jingchang Lu <[email protected]> Signed-off-by: Srikanth Srinivasan <[email protected]> Signed-off-by: Roy Zang <[email protected]> Acked-by: Wan ZongShun <[email protected]> Cc: Kumar Gala <[email protected]> Cc: Alessandro Zummo <[email protected]> Signed-off-by: Andrew Morton <[email protected]> Signed-off-by: Linus Torvalds <[email protected]>
2010-08-11rtc/nuc900: fix build warningWan ZongShun1-1/+1
Remove unused local variable. Signed-off-by: Wan ZongShun <[email protected]> Cc: Alessandro Zummo <[email protected]> Signed-off-by: Andrew Morton <[email protected]> Signed-off-by: Linus Torvalds <[email protected]>
2010-08-11rtc/nuc900: modify enable/disable IRQs and driver data setting locationWan ZongShun1-11/+12
This patch does two modifications: (1) Adjust enable/disable IRQs location,enable it after rtc registration and disable it prior to unregistration. (2) Put 'platform_set_drvdata(pdev, nuc900_rtc)' in front of rtc registration still be safety, though there is no need to do this, when I move enable irq after rtc registration, I think still put 'platform_set_drvdata' before rtc registration that would be a good habit. Signed-off-by: Wan ZongShun <[email protected]> Cc: Alessandro Zummo <[email protected]> Signed-off-by: Andrew Morton <[email protected]> Signed-off-by: Linus Torvalds <[email protected]>
2010-08-11rtc/nuc900: make returning time checking function validWan ZongShun1-8/+4
Make returning time checking function valid. In spite of using the 'rtc_valid_tm', nevertheless, the read time function omits its returning value, that means the 'rtc_valid_tm' is useless here. Signed-off-by: Wan ZongShun <[email protected]> Cc: Alessandro Zummo <[email protected]> Signed-off-by: Andrew Morton <[email protected]> Signed-off-by: Linus Torvalds <[email protected]>
2010-08-11rtc/m48t86: use rtc_valid_tm() to check returned tmWan ZongShun1-1/+1
Use rtc_valid_tm() to check the returned struct rtc_time *tm, to avoid returning a wrong tm value. Signed-off-by: Wan ZongShun <[email protected]> Cc: Paul Gortmaker <[email protected]> Cc: Alessandro Zummo <[email protected]> Signed-off-by: Andrew Morton <[email protected]> Signed-off-by: Linus Torvalds <[email protected]>
2010-08-11rtc/m48t59: use rtc_valid_tm() to check returned tmWan ZongShun1-2/+2
Use rtc_valid_tm to check the returned struct rtc_time *tm, to avoid returning a wrong tm value. Signed-off-by: Wan ZongShun <[email protected]> Cc: Paul Gortmaker <[email protected]> Cc: Alessandro Zummo <[email protected]> Signed-off-by: Andrew Morton <[email protected]> Signed-off-by: Linus Torvalds <[email protected]>
2010-08-11rtc/max6900: use rtc_valid_tm() to check returning tmWan ZongShun1-1/+1
Use rtc_valid_tm() to check returning tm for max6900, it can avoid returning wrong tm value. Signed-off-by: Wan ZongShun <[email protected]> Acked-by: Dale Farnsworth <[email protected]> Cc: Alessandro Zummo <[email protected]> Signed-off-by: Andrew Morton <[email protected]> Signed-off-by: Linus Torvalds <[email protected]>
2010-08-11rtc/m41t80: use rtc_valid_tm() to check returned tmWan ZongShun1-2/+2
Use rtc_valid_tm() to check returned struct rtc_time *tm - it can avoid returning wrong tm value. Signed-off-by: Wan ZongShun <[email protected]> Cc: Alessandro Zummo <[email protected]> Signed-off-by: Andrew Morton <[email protected]> Signed-off-by: Linus Torvalds <[email protected]>
2010-08-11rtc: add Intersil ISL12022 RTC driverRoman Fietze3-0/+337
- derived from rtc-pcf8563 - no SRAM driver Signed-off-by: Roman Fietze <[email protected]> Cc: Wan ZongShun <[email protected]> Cc: Alessandro Zummo <[email protected]> Signed-off-by: Andrew Morton <[email protected]> Signed-off-by: Linus Torvalds <[email protected]>
2010-08-11rtc: driver for the DryIce block found in i.MX25 chipsBaruch Siach3-0/+530
This driver is based on code from Freescale which accompanies their i.MX25 PDK board, with some cleanup. Signed-off-by: Baruch Siach <[email protected]> Cc: Alessandro Zummo <[email protected]> Cc: Sascha Hauer <[email protected]> Acked-by: Wan ZongShun <[email protected]> Cc: Alessandro Zummo <[email protected]> Signed-off-by: Andrew Morton <[email protected]> Signed-off-by: Linus Torvalds <[email protected]>
2010-08-11drivers/rtc/rtc-pl031.c: remove unused #include <linux/version.h>Huang Weiyi1-1/+0
Signed-off-by: Huang Weiyi <[email protected]> Acked-by: Wan ZongShun <[email protected]> Cc: Alessandro Zummo <[email protected]> Signed-off-by: Andrew Morton <[email protected]> Signed-off-by: Linus Torvalds <[email protected]>
2010-08-11rtc/pxa: remove unnecessary private ops->ioctl()Wan ZongShun1-19/+22
We shouldn't implement private ops->ioctl() unless absolutely necessary. pxa series RTC driver's ioctl() is unnecessary, since RTC subsystem has implement the ioctl() very well,so we can only use the API of '.alarm_irq_enable' and '.update_irq_enable' to do enable irq action. Signed-off-by: Wan ZongShun <[email protected]> Acked-by: Robert Jarzmik <[email protected]> Acked-by: Eric Miao <[email protected]> Cc: Paul Gortmaker <[email protected]> Cc: Alessandro Zummo <[email protected]> Signed-off-by: Andrew Morton <[email protected]> Signed-off-by: Linus Torvalds <[email protected]>
2010-08-11rtc: fixes and new functionality for fm3130Sergey Matyukevich1-51/+130
- add sanity check for alarm data in fm3130_probe - fix fm3130_set_alarm. According to the datasheet, setting match bit '0' indicates that the corresponding alarm field will be used in the match process - add operation alarm_irq_enable operation which is responsible for handling RTC_AIE_ON, RTC_AIE_OFF ioctls - remove clearing of AF bit after reading rtc/alarm control register: according to datasheet this bit is cleared anyway when rtc/alarm control register is read [[email protected]: make fm3130_alarm_irq_enable() static, fix comment layout] Signed-off-by: Sergey Matyukevich <[email protected]> Acked-by: Wan ZongShun <[email protected]> Acked-by: Sergey Lapin <[email protected]> Cc: Alessandro Zummo <[email protected]> Signed-off-by: Andrew Morton <[email protected]> Signed-off-by: Linus Torvalds <[email protected]>
2010-08-11rtc/rtc-mxc: remove six unused fieldsWan ZongShun1-6/+0
Remove six unused fields from `struct rtc_plat_data'. Signed-off-by: Wan ZongShun <[email protected]> Cc: Alessandro Zummo <[email protected]> Cc: Paul Gortmaker <[email protected]> Signed-off-by: Andrew Morton <[email protected]> Signed-off-by: Linus Torvalds <[email protected]>
2010-08-11rtc/m48t59: kfree(NULL) is OKWan ZongShun1-1/+0
Signed-off-by: Wan ZongShun <[email protected]> Cc: Alessandro Zummo <[email protected]> Cc: Paul Gortmaker <[email protected]> Signed-off-by: Andrew Morton <[email protected]> Signed-off-by: Linus Torvalds <[email protected]>
2010-08-11rtc/pxa: remove unused fieldWan ZongShun1-1/+0
pxa_rtc.rtc_alarm is unused. Signed-off-by: Wan ZongShun <[email protected]> Cc: Eric Miao <[email protected]> Cc: Alessandro Zummo <[email protected]> Signed-off-by: Andrew Morton <[email protected]> Signed-off-by: Linus Torvalds <[email protected]>
2010-08-11drivers/rtc/rtc-pcf8563.c: remove unused structGraham Gower1-8/+0
Signed-off-by: Graham Gower <[email protected]> Acked-by: Wan ZongShun <[email protected]> Cc: Alessandro Zummo <[email protected]> Signed-off-by: Andrew Morton <[email protected]> Signed-off-by: Linus Torvalds <[email protected]>
2010-08-11rtc/nuc900: fix checking of args during time-settingWan ZongShun1-4/+10
When a user application wants to set the rtc time, the RTC subsystem takes advantage of 'rtc_valid_tm(tm)' to check 'rtc_time *tm' value validity, it make sure the 'tm->tm_year' is larger than 70,so if '70< tm_year < 100', the '(settm->tm_year - 100)' will be negative. ' Setting the negative value to hardware register will be invalid, so I add the 'if' condition to make sure set a valid value to register. Signed-off-by: Wan ZongShun <[email protected]> Cc: Alessandro Zummo <[email protected]> Signed-off-by: Andrew Morton <[email protected]> Signed-off-by: Linus Torvalds <[email protected]>
2010-08-11nuc900/rtc: change the waiting for device ready implementWan ZongShun1-8/+7
- add an mdelay(1) to the polling loop to cause less frequent access to the hardware register. - change the return value from ENODEV to EPERM if the loop timed out. I think the 'Operation not permitted' description is more suitable for the meaning of 'check_rtc_access_enable()' function, it just be used to judge rtc access operation is permitted or not. Signed-off-by: Wan ZongShun <[email protected]> Cc: Alessandro Zummo <[email protected]> Signed-off-by: Andrew Morton <[email protected]> Signed-off-by: Linus Torvalds <[email protected]>
2010-08-11autofs4: remove unneeded null check in try_to_fill_dentry()Dan Carpenter1-2/+1
After 97e7449a7ad: "autofs4: fix indirect mount pending expire race" we no longer assumed that "ino" can be null. The other null checks got removed but this was one was missed. Signed-off-by: Dan Carpenter <[email protected]> Cc: Ian Kent <[email protected]> Cc: Al Viro <[email protected]> Signed-off-by: Andrew Morton <[email protected]> Signed-off-by: Linus Torvalds <[email protected]>
2010-08-11i2o: check return code from put_user()Kulikov Vasiliy1-7/+9
Check return value of put_user() and return -EFAULT if it failed. Original comment "We did a get user...so assuming mem is ok...is this bad?" is incorrect because memory can be read only. Signed-off-by: Kulikov Vasiliy <[email protected]> Signed-off-by: Andrew Morton <[email protected]> Signed-off-by: Linus Torvalds <[email protected]>
2010-08-11i2o: fix overflow of copy_to_user()Kulikov Vasiliy1-1/+1
If (len > reslen) we must not call copy_to_user() since kernel buffer is smaller than we want to copy. Similar code in this file is correct, so this bug was a typo. Signed-off-by: Kulikov Vasiliy <[email protected]> Signed-off-by: Andrew Morton <[email protected]> Signed-off-by: Linus Torvalds <[email protected]>
2010-08-11drivers/message/i2o/exec-osm.c: add missing mutex_unlockJulia Lawall1-2/+6
Add a mutex_unlock missing on the error path. The semantic match that finds this problem is as follows: (http://coccinelle.lip6.fr/) // <smpl> @@ expression E1; @@ * mutex_lock(E1,...); <+... when != E1 if (...) { ... when != E1 * return ...; } ...+> * mutex_unlock(E1,...); // </smpl> Signed-off-by: Julia Lawall <[email protected]> Signed-off-by: Andrew Morton <[email protected]> Signed-off-by: Linus Torvalds <[email protected]>
2010-08-11mmc: add ricoh e822 pci idPablo Castillo1-0/+8
Signed-off-by: Pablo Castillo <[email protected]> Signed-off-by: Stanislaw Gruszka <[email protected]> Tested-by: Gregg Lebovitz <[email protected]> Cc: Maxim Levitsky <[email protected]> Signed-off-by: Andrew Morton <[email protected]> Signed-off-by: Linus Torvalds <[email protected]>
2010-08-11dts: add ESDHC weird voltage bits workaroundRoy Zang1-0/+1
P4080 ESDHC controller does not support 1.8V and 3.0V voltage. but the host controller capabilities register wrongly set the bits. This patch adds the workaround to correct the weird voltage setting bits. Only 3.3V voltage is supported for P4080 ESDHC controller. Signed-off-by: Roy Zang <[email protected]> Cc: Jerry Huang <[email protected]> Cc: Benjamin Herrenschmidt <[email protected]> Cc: Kumar Gala <[email protected]> Cc: Grant Likely <[email protected]> Cc: <[email protected]> Signed-off-by: Andrew Morton <[email protected]> Signed-off-by: Linus Torvalds <[email protected]>
2010-08-11dts: add sdhci,auto-cmd12 field for p4080 device treeRoy Zang2-0/+3
Signed-off-by: Roy Zang <[email protected]> Cc: Jerry Huang <[email protected]> Cc: Benjamin Herrenschmidt <[email protected]> Cc: Kumar Gala <[email protected]> Cc: Grant Likely <[email protected]> Cc: <[email protected]> Signed-off-by: Andrew Morton <[email protected]> Signed-off-by: Linus Torvalds <[email protected]>
2010-08-11sdhci: add auto CMD12 support for eSDHC driverJerry Huang3-2/+18
Add auto CMD12 command support for eSDHC driver. This is needed by P4080 and P1022 for block read/write. Manual asynchronous CMD12 abort operation causes protocol violations on these silicons. Signed-off-by: Jerry Huang <[email protected]> Signed-off-by: Roy Zang <[email protected]> Cc: Benjamin Herrenschmidt <[email protected]> Cc: Kumar Gala <[email protected]> Cc: Grant Likely <[email protected]> Cc: <[email protected]> Signed-off-by: Andrew Morton <[email protected]> Signed-off-by: Linus Torvalds <[email protected]>
2010-08-11sdhci: add regulator supportMarek Szyprowski2-1/+27
This patch adds support for regulator API to sdhci core driver. Regulators can be used to disable power in suspended state to reduce dissipated energy. Signed-off-by: Marek Szyprowski <[email protected]> Signed-off-by: Kyungmin Park <[email protected]> Acked-by: Mark Brown <[email protected]> Cc: <[email protected]> Signed-off-by: Andrew Morton <[email protected]> Signed-off-by: Linus Torvalds <[email protected]>
2010-08-11sdhci-s3c: add support for new card detection methodsMarek Szyprowski2-0/+86
On some Samsung SoCs not all SDHCI controllers have card detect (CD) line. For some embedded designs it is not even needed, because ususally the device (like SDIO flash memory or wifi controller) is permanently wired to the controller. There are also systems which have a card detect line connected to some of the external interrupt lines or the presence of the card depends on some other actions (like enabling a power regulator). This patch adds support for all these cases. The following card detection methods are possible: 1. internal sdhci host card detect line 2. external event 3. external gpio interrupt 4. no card detect line, controller will poll for the card 5. no card detect line, card is permanently wired to the controller (once detected host won't poll it any more) By default, all existing code would use method #1, what is compatible with the previous version of the driver. In case of external event, two callbacks must be provided in platdata: ext_cd_init and ext_cd_cleanup. Both of them get a callback to a function that notifies the s3c-sdhci host contoller as their argument. That callback function should be called from the even dispatcher to let host notice the card insertion/removal. In case of external gpio interrupt, a gpio pin number must be provided in platdata (ext_cd_gpio parameter), as well as the information about the polarity of that gpio pin (ext_cd_gpio_invert). By default (ext_cd_gpio_invert == 0) gpio value 0 means 'card has been removed', but this can be changed to 'card has been removed' when ext_cd_gpio_invert == 1. This patch adds all required changes to sdhci-s3c driver. Signed-off-by: Marek Szyprowski <[email protected]> Signed-off-by: Kyungmin Park <[email protected]> Cc: <[email protected]> Signed-off-by: Andrew Morton <[email protected]> Signed-off-by: Linus Torvalds <[email protected]>