提交 3fb3b3c4 编写于 作者: A Alexander Dahl 提交者: Alexandre Belloni

memory: atmel-ebi: Fix smc cycle xlate converter

The converter function for translating ns timings in register values was
initialized with a wrong function pointer. This resulted in wrong
register values also for the setup and pulse registers when configuring
the EBI interface trough dts.

Includes a small fix in a comment of the smc driver, which was probably
just a copy'n'paste mistake.
Signed-off-by: NAlexander Dahl <ada@thorsis.com>
Acked-by: NBoris Brezillon <boris.brezillon@free-electrons.com>
Acked-by: NLee Jones <lee.jones@linaro.org>
Signed-off-by: NAlexandre Belloni <alexandre.belloni@free-electrons.com>
上级 1f6b5390
...@@ -72,7 +72,7 @@ struct atmel_smc_timing_xlate { ...@@ -72,7 +72,7 @@ struct atmel_smc_timing_xlate {
{ .name = nm, .converter = atmel_smc_cs_conf_set_pulse, .shift = pos} { .name = nm, .converter = atmel_smc_cs_conf_set_pulse, .shift = pos}
#define ATMEL_SMC_CYCLE_XLATE(nm, pos) \ #define ATMEL_SMC_CYCLE_XLATE(nm, pos) \
{ .name = nm, .converter = atmel_smc_cs_conf_set_setup, .shift = pos} { .name = nm, .converter = atmel_smc_cs_conf_set_cycle, .shift = pos}
static void at91sam9_ebi_get_config(struct atmel_ebi_dev *ebid, static void at91sam9_ebi_get_config(struct atmel_ebi_dev *ebid,
struct atmel_ebi_dev_config *conf) struct atmel_ebi_dev_config *conf)
......
...@@ -206,7 +206,7 @@ EXPORT_SYMBOL_GPL(atmel_smc_cs_conf_set_pulse); ...@@ -206,7 +206,7 @@ EXPORT_SYMBOL_GPL(atmel_smc_cs_conf_set_pulse);
* parameter * parameter
* *
* This function encodes the @ncycles value as described in the datasheet * This function encodes the @ncycles value as described in the datasheet
* (section "SMC Pulse Register"), and then stores the result in the * (section "SMC Cycle Register"), and then stores the result in the
* @conf->setup field at @shift position. * @conf->setup field at @shift position.
* *
* Returns -EINVAL if @shift is invalid, -ERANGE if @ncycles does not fit in * Returns -EINVAL if @shift is invalid, -ERANGE if @ncycles does not fit in
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册