aboutsummaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
2009-08-11Merge branch 'drm-tracking' of ↵Thomas White
git+ssh://git-weiss@git.bitwiz.org.uk/srv/git-public/kernel into drm-tracking
2009-08-11Update licence boilerplateThomas White
Signed-off-by: Thomas White <taw@bitwiz.org.uk>
2009-08-06Tidy up, and remove debugThomas White
Tidy up a few lines, and remove debug lines which would slow us down. Signed-off-by: Thomas White <taw@bitwiz.org.uk>
2009-08-06Put the mutex functions the right way roundThomas White
Signed-off-by: Thomas White <taw@bitwiz.org.uk>
2009-08-04ioremap() the framebuffer properlyThomas White
This fixes the glamo-kms-fb initialisation to ioremap() the proper address for the framebuffer, rather than just assuming it's at the start of the VRAM. Signed-off-by: Thomas White <taw@bitwiz.org.uk>
2009-08-04Tidy up initialisationThomas White
Fix label usage, making a compiler warning go away in the process. Signed-off-by: Thomas White <taw@bitwiz.org.uk>
2009-08-04Keep glamo-kms-fb off the hardware registersThomas White
This removes the last remaining instance of glamo-kms-fb touching Glamo's registers directly. Signed-off-by: Thomas White <taw@bitwiz.org.uk>
2009-08-04Copyright and debugThomas White
Update the copyright notice to include proper BSD credit for the memory mapping in glamo-buffer.c. Also removes some superfluous debug messages. Signed-off-by: Thomas White <taw@bitwiz.org.uk>
2009-08-04Take FB allocation back down to the minimumThomas White
This doesn't work with the current 'standard' DDX, so there's no point trying to make it work. Signed-off-by: Thomas White <taw@bitwiz.org.uk>
2009-08-02GTA02: add support for dumb battery driverPaul Fertser
This allows to use gta01 battery driver on gta02. echo bq27000-battery.0 > /sys/bus/platform/drivers/bq27000-battery/unbind modprobe gta01_battery Signed-off-by: Paul Fertser <fercerpav@gmail.com>
2009-08-02gta02: use a dedicated function to query usb online statusPaul Fertser
We need to use a dedicated function because we can't get charger status from an irq context and that is required by usb gadgets. Signed-off-by: Paul Fertser <fercerpav@gmail.com>
2009-08-02pcf50633: query charger status directlyPaul Fertser
Current scheme is fragile and is likely to go off sync, especially on batfull->adapter charging automatic MBC transition. Query the status bit every time we need it instead. We need to export another function to query for USB presence because we can't read anything from PCF50633 (via I2C) inside irq context and that is needed by usb gadgets. Signed-off-by: Paul Fertser <fercerpav@gmail.com>
2009-08-02pcf50633: properly reenable charging when the supply conditions changePaul Fertser
If chgmod == BATFULL, setting chgena has no effect. Datasheet says we need to set resume instead but when autoresume is used resume doesn't work. Clear and set chgena instead. This enables a user to force charging by re-plugging USB even when the charger entered Battery Full mode, might be handy before a long trip. Signed-off-by: Paul Fertser <fercerpav@gmail.com>
2009-08-02pcf50633: get rid of charging restart software auto-triggeringPaul Fertser
After reaching Battery Full condition MBC state machine switches back into charging mode when the battery voltage falls below 96% of a battery float voltage. The voltage drop in Li-Ion batteries is marginal (1-2%) till about 80% of its capacity - which means, after a BATFULL, charging won't be restarted until 75-80%. That is a desired behaviour recommended by battery manufacturers, don't mess with it. Signed-off-by: Paul Fertser <fercerpav@gmail.com>
2009-08-02pcf50633: fix wrong define for 10bit ADC modePaul Fertser
Signed-off-by: Paul Fertser <fercerpav@gmail.com>
2009-08-02pcf50633: revise locking for ADCPaul Fertser
Current implementation is prone to races, this patch attempts to remove all but one (in pcf50633_adc_sync_read). The idea is that we need to guard the queue access only on inserting and removing items. If we insert and there're no more items in the queue it means that the last irq already happened and we need to trigger ADC manually. If not, then the next conversion will be triggered by the irq handler upon completion of the previous. Signed-off-by: Paul Fertser <fercerpav@gmail.com>
2009-08-02pcf50633: use a dedicated workqueue for irq processingPaul Fertser
Using the default kernel "events" workqueue causes problems with synchronous adc readings if initiated from some task on the same workqueue. I had a deadlock trying to use pcf50633_adc_sync_read from a power_supply class driver because the reading was initiated from the workqueue and it waited for the irq processing to complete (to get the result) and that was put on the same workqueue. Signed-off-by: Paul Fertser <fercerpav@gmail.com>
2009-08-02gta02: charging_restart_interval should no longer be used, count on MBC ↵Paul Fertser
auto-restart Signed-off-by: Paul Fertser <fercerpav@gmail.com>
2009-08-02gta01_battery: add charge_{now,full} propertiesPaul Fertser
Some userspace (notably Enlightment's batget) ignores "capacity" completely if there're no other properties. Expose a fake value (850mAh, typical for BL-5C) to make them happy. Signed-off-by: Paul Fertser <fercerpav@gmail.com>
2009-08-02gta01_battery: generalise the driver, add capacity estimationPaul Fertser
Check if machine-specific hooks exist before calling, this allows to use this driver with gta02 or any other device that is able to provide battery voltage readings. Report an estimate of capacity percentage left, based on discharge curves. Strictly speaking, this is a violation of power_supply class specs but since this is the only driver for dumb batteries and userspace lacks any library to do the estimation itself, we have to stuff it here. Please keep in mind that this estimation is by no means accurate, usually cell phones have only 5 bars to represent charge status. Credit goes to Joerg Reisenweber and SpeedEvil for helping with gathering and analysing the data. Signed-off-by: Paul Fertser <fercerpav@gmail.com>
2009-08-02gta01_battery: fix unloading bugPaul Fertser
Driver data must be properly registered after allocation Signed-off-by: Paul Fertser <fercerpav@gmail.com>
2009-07-30Implement glamo_ioctl_gem_mmap(), properly this timeThomas White
Signed-off-by: Thomas White <taw@bitwiz.org.uk>
2009-07-29Implement glamo_crtc_mode_set_base()Thomas White
Signed-off-by: Thomas White <taw@bitwiz.org.uk>
2009-07-29Set minimum and maximum dimensions in mode configThomas White
Signed-off-by: Thomas White <taw@bitwiz.org.uk>
2009-07-27gta02: fix compile without CHARGER_PCF50633Lars-Peter Clausen
gta02_pmu_force_shutdown is only defined when CONFIG_CHARGER_PCF50633 is set, but it's used unconditionally. Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>
2009-07-27bq27000: Return -ENODEV in bq27000_battery_get_property if the battery is notLars-Peter Clausen
If the battery is not present hdq_read will always return an error. If the drivers knows that the battery is not present the correct thing to do is to return -ENODEV instead of passing the error on. Do this for all properties except POWER_SUPPLY_PROP_PRESENT. The power supply sysfs expects us to do so, else it won't generate a proper uevent file. Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>
2009-07-15Tidy upThomas White
This just alters some formatting and removes old code. Signed-off-by: Thomas White <taw@bitwiz.org.uk>
2009-07-15Bring gta02_drm_config up to date with gta02_packaging_defconfigThomas White
Signedy-off-by: Thomas White <taw@bitwiz.org.uk>
2009-07-15Merge branch 'drm-kms' into drm-trackingThomas White
Conflicts: drivers/mfd/glamo/glamo-cmdq.c drivers/mfd/glamo/glamo-cmdq.h drivers/mfd/glamo/glamo-drm-drv.c drivers/mfd/glamo/glamo-drm-private.h Signed-off-by: Thomas White <taw@bitwiz.org.uk>
2009-07-11De-bodge pixel clocksThomas White
.. or re-bodge them, depending on your perspective. This makes mode->clock contain a value in Hz, in line with the KMS convention. This is at the expense of more calculations when generating the mode from the mach_info and when setting the mode. Signed-off-by: Thomas White <taw@bitwiz.org.uk>
2009-07-09DebugThomas White
Just a little bit more debug information Signed-off-by: Thomas White <taw@bitwiz.org.uk>
2009-07-09Expose more memory via glamo-kms-fbThomas White
This increases the amount of memory exposed via the framebuffer. This should eventually allow an fbdev-based DDX or a KMS DDX to run on the same kernel, albeit suboptimally. Signed-off-by: Thomas White <taw@bitwiz.org.uk>
2009-07-09Fix resume, part 2Thomas White
This removes a bogus check of var->pixclock. With KMS, this value is not relevant. Signed-off-by: Thomas White <taw@bitwiz.org.uk>
2009-07-06Fix resume, part 1Thomas White
This seems to fix the kernel-level suspend/resume. There remains a problem which causes Xorg to crash on resume. Signed-off-by: Thomas White <taw@bitwiz.org.uk>
2009-07-05GTA01: fix current and voltage reporting unitsPaul Fertser
According to power_supply class specification all voltages and currents must be reported in uV and uA correspondingly. Signed-off-by: Paul Fertser <fercerpav@gmail.com>
2009-07-05ASoC: Fix wm8753 register cache size and initializationLars-Peter Clausen
Register cache space was not being allocated for the final register, causing bugs when it was used. Allocate space for it. Also ensure that the final register is displayed in sysfs. [Commit message rewritten to document actual issue. -- broonie] Signed-off-by: Lars-Peter Clausen <lars@metafoo.de> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-07-05ASoC: Fix register cache initialisation for WM8753Mark Brown
The wrong register cache variable was being used to provide the size for the memcpy(), resulting in a copy of only a void * of data. Reported-by: Lars-Peter Clausen <lars@metafoo.de> Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
2009-07-02Initial suspend/resumeThomas White
Doesn't work yet... Signed-off-by: Thomas White <taw@bitwiz.org.uk>
2009-07-02More whitespaceThomas White
Fix a whitespace error introduced by the earlier debug stuff. Signed-off-by: Thomas White <taw@bitwiz.org.uk>
2009-07-02Update gta02_drm_defconfigThomas White
Alter the "DRM defconfig" to match the packaging config with minimal tweaks for DRM. Signed-off-by: Thomas White <taw@bitwiz.org.uk>
2009-07-02WhitespaceThomas White
Fix trailing whitespace Signed-off-by: Thomas White <taw@bitwiz.org.uk>
2009-07-02Alter jbt6k74 state on DPMSThomas White
This uses the "stopgap" method implemented earlier. Signed-off-by: Thomas White <taw@bitwiz.org.uk>
2009-07-02Do not switch the screen off when changing modeThomas White
...because the clock(s) must be running while we talk to the chip. Signed-off-by: Thomas White <taw@bitwiz.org.uk>
2009-07-01Remove debug watchpointsThomas White
Finished with these now. Signed-off-by: Thomas White <taw@bitwiz.org.uk>
2009-07-01Fix scanout timingsThomas White
This fixes the scanout timing conversion so that it works. Signed-off-by: Thomas White <taw@bitwiz.org.uk>
2009-07-01Nasty jbt stuffThomas White
This adds a stopgap measure to permit manipulation of the LCD controller chip in the absence of an fb notifier chain. It also adds some messing around with the DPMS stuff. Signed-off-by: Thomas White <taw@bitwiz.org.uk>
2009-07-01DebugThomas White
This adds some register debugging watchpoints Signed-off-by: Thomas White <taw@bitwiz.org.uk>
2009-07-01Compatibility glamo-drm <---> glamo-fbThomas White
Signed-off-by: Thomas White <taw@bitwiz.org.uk>
2009-06-30Enable the LCD engineThomas White
Well, duh. Signed-off-by: Thomas White <taw@bitwiz.org.uk>
2009-06-30Whitespace and debuggingThomas White
Signed-off-by: Thomas White <taw@bitwiz.org.uk>