Commit Graph

19 Commits

Author SHA1 Message Date
Tomasz Figa 7c93c200f6 ARM: SAMSUNG: Remove pwm-clock infrastructure
Since all the used PWM prescalers and dividers configuration has been
moved to appropriate drivers, the pwm-clock infrastructure is now
unused and so this patch removes it.

Signed-off-by: Tomasz Figa <tomasz.figa@gmail.com>
Reviewed-by: Sylwester Nawrocki <s.nawrocki@samsung.com>
Tested-by: Heiko Stuebner <heiko@sntech.de>
Tested-by: Mark Brown <broonie@linaro.org>
Tested-by: Sylwester Nawrocki <sylvester.nawrocki@gmail.com>
Acked-by: Arnd Bergmann <arnd@arndb.de>
2013-08-12 21:53:24 +02:00
Sylwester Nawrocki d817468c4b ARM: S3C24XX: Add missing clkdev entries for s3c2440 UART
This patch restores serial port operation which has been broken since
commit 60e9357547 ("serial: samsung: enable clock before clearing
pending interrupts during init")

That commit only uncovered the real issue which was missing clkdev
entries for the "uart" clocks on S3C2440. It went unnoticed so far
because return value of clk API calls were not being checked at all
in the samsung serial port driver.

This patch should be backported to at least 3.10 stable kernel, since
the serial port has not been working on s3c2440 since 3.10-rc5.

Cc: Chander Kashyap <chander.kashyap@linaro.org>
Signed-off-by: Sylwester Nawrocki <sylvester.nawrocki@gmail.com>
[on S3C2440 SoC based Mini2440 board]
Tested-by: Sylwester Nawrocki <sylvester.nawrocki@gmail.com>
Reviewed-by: Tomasz Figa <t.figa@samsung.com>
Tested-by: Juergen Beisert <jbe@pengutronix.de>
Cc: <stable@vger.kernel.org>	[3.10]
Signed-off-by: Kukjin Kim <kgene.kim@samsung.com>
2013-07-24 13:23:51 +09:00
Heiko Stuebner 7d9811f11f ARM: S3C24XX: remove XXX_setup_clocks method from S3C2443
s3c2443_common_setup_clocks is always called through
s3c2443_common_init_clocks, so there is no need to call it separately.
It was also called twice through this separate call.

Signed-off-by: Heiko Stuebner <heiko@sntech.de>
Signed-off-by: Kukjin Kim <kgene.kim@samsung.com>
2012-03-07 02:00:04 -08:00
Heiko Stuebner 507164d223 ARM: S3C2410: move s3c2410_baseclk_add to clock.h
plat-samsung/clock.h currently keeps all the SoC specific clock
declarations. As we want to get rid of s3c2410.h altogether, move
the s3c2410_baseclk_add there too.

Signed-off-by: Heiko Stuebner <heiko@sntech.de>
Signed-off-by: Kukjin Kim <kgene.kim@samsung.com>
2012-01-31 20:06:43 +09:00
Heiko Stuebner 4083da3dcd ARM: S3C24XX: move common S3C2443 clock definitions to clock.h
plat-samsung/clock.h currently keeps all the SoC specific clock
declarations except the ones for S3C2443/S3C2416 which were kept in
s3c2443.h.

This patch moves them out of s3c2443.h to get rid of the header
completely later on.

Signed-off-by: Heiko Stuebner <heiko@sntech.de>
Signed-off-by: Kukjin Kim <kgene.kim@samsung.com>
2012-01-31 20:06:42 +09:00
Kukjin Kim 3a0ec25954 ARM: SAMSUNG: fix to prevent declaring duplicated
The plat/clock.h revised to prevent declaring duplicated.

Signed-off-by: Kukjin Kim <kgene.kim@samsung.com>
2011-09-15 15:54:15 +09:00
Marek Szyprowski caf27307fa ARM: SAMSUNG: fix watchdog reset issue with clk_get()
clkdev framework uses global mutex to protect clock tree, so it is not
possible to call clk_get() in interrupt context. This patch fixes this
issue and makes system reset by watchdog call working again.

Signed-off-by: Marek Szyprowski <m.szyprowski@samsung.com>
Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com>
Signed-off-by: Kukjin Kim <kgene.kim@samsung.com>
2011-09-15 13:59:58 +09:00
Thomas Abraham f86c666092 ARM: SAMSUNG: Add clkdev infrastructure
The struct clk definition for Samsung platforms is extended to include
a instance of struct clk_lookup and a device name. When clocks are
registered using s3c24xx_register_clock function, the dev_id, con_id
and clk members are initialized with information from the struct clk
instance and struct clk_lookup member is registered.

Signed-off-by: Thomas Abraham <thomas.ab@samsung.com>
Signed-off-by: Kukjin Kim <kgene.kim@samsung.com>
2011-07-20 19:11:28 +09:00
Lucas De Marchi 25985edced Fix common misspellings
Fixes generated by 'codespell' and manually reviewed.

Signed-off-by: Lucas De Marchi <lucas.demarchi@profusion.mobi>
2011-03-31 11:26:23 -03:00
Amit Daniel Kachhap 436c387841 ARM: SAMSUNG: Add support for clock debugging through debug-fs interface
This patch adds support for clock information exposed to debug-fs interface.

Signed-off-by: Amit Daniel Kachhap <amit.daniel@samsung.com>
[kgene.kim@samsung.com: removed useless empty lines]
Signed-off-by: Kukjin Kim <kgene.kim@samsung.com>
2011-01-12 13:40:04 +09:00
Ben Dooks 32457942b9 ARM: Merge for-2635/fb-updates1
Merge branch 'for-2635/fb-updates1' into for-linus/samsung2
2010-05-19 18:04:11 +09:00
Maurus Cuelenaere 05e021f095 ARM: S3C64XX: Add USB external clock definition
This adds the xusbxti clock to S3C64XX platform.

Signed-off-by: Maurus Cuelenaere <mcuelenaere@gmail.com>
Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2010-05-18 18:21:59 +09:00
Ben Dooks 4e04691bc6 ARM: SAMSUNG: Add s3c_disable_clocks() and tidy init+disable usage
Add s3c_disable_clocks() and change the clock registration code to use
the s3c_register_clocks() followed by s3c_disable_clocks() instead of
the loops it was using.

Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2010-05-10 11:44:38 +09:00
Ben Dooks 55bf9267dd ARM: S3C64XX: Combine the clock init code
Turn the init sequence of
	s3c24xx_register_baseclocks(xtal);
	s3c64xx_register_clocks();
	s3c6400_register_clocks(S3C6410_CLKDIV0_ARM_MASK);

into a single call as this is now contained within one file.

Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2010-02-20 22:34:02 +00:00
Kukjin Kim 1a0e8a52ad ARM: S5P6440: Add Clock and PLL support
This patch adds clock and pll support for S5P6440. This patch are based on
Harald Welte's patches and Ben's plat-samsung.

Signed-off-by: Thomas Abraham <thomas.ab@samsung.com>
Signed-off-by: Kukjin Kim <kgene.kim@samsung.com>
Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2010-01-15 19:16:16 +09:00
Kukjin Kim ed276849bc ARM: SAMSUNG: Make clk_default_setrate and clk_ops_def_setrate visible
This patch makes clk_default_setrate and clk_ops_def_setrate available
to code outside plat-samsung clock code.

Signed-off-by: Thomas Abraham <thomas.ab@samsung.com>
Signed-off-by: Kukjin Kim <kgene.kim@samsung.com>
Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2010-01-15 17:10:12 +09:00
Ben Dooks 1d9f13c49e ARM: SAMSUNG: Add call to register array of clocks
Add s3c_register_clocks() to register an array of clocks, printing
an error message if there is a problem. Replace all points in the code
where this could be used.

Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2010-01-15 17:10:11 +09:00
Ben Dooks b3bf41be06 ARM: SAMSUNG: Reduce size of struct clk.
Reduce the size of struct clk by 12 bytes and make defining clocks with
common implementation functions easier by moving the set_rate, get_rate,
round_rate and set_parent calls into a new structure called 'struct clk_ops'
and using that instead.

This change does make a few clocks larger as they need their own clk_ops,
but this is outweighed by the number of clocks with either no ops or having
a common set of ops.

Update all the users of this.

Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2010-01-15 17:10:10 +09:00
Ben Dooks 70792bcfad ARM: SAMSUNG: Move <plat/clock.h> to plat-samsung
Move the <plat/clock.h> header to plat-samsung where it can be used by all
the platforms, and readies it for the next round of clock updates where
the clock code will be amalgamated.

Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2010-01-15 17:10:08 +09:00