From: Ben Dooks <ben@simtec.co.uk>
To: linux-arm-kernel@lists.arm.linux.org.uk
Cc: Linux MTD <linux-mtd@lists.infradead.org>
Subject: [patch 1/2] kirkwood: allow machines to register RnB line with mtd driver
Date: Fri, 30 Apr 2010 00:11:37 +0100 [thread overview]
Message-ID: <20100429231204.169647403@fluff.org.uk> (raw)
In-Reply-To: 20100429231136.086930268@fluff.org.uk
[-- Attachment #1: slinux/arm/kirkwood/allow-mtd-ready-not-busy-registration.patch --]
[-- Type: text/plain, Size: 1855 bytes --]
Add a kirkwood_nand_init_rnb() call to allow boards which
have RnB line detection to register this instead of a
static delay.
Signed-off-by: Ben Dooks <ben@simtec.co.uk>
Cc: Linux MTD <linux-mtd@lists.infradead.org>
Index: linux-2.6-2.6.32.9/arch/arm/mach-kirkwood/common.c
===================================================================
--- linux-2.6-2.6.32.9.orig/arch/arm/mach-kirkwood/common.c 2010-02-23 15:38:51.%N +0000
+++ linux-2.6-2.6.32.9/arch/arm/mach-kirkwood/common.c 2010-03-11 13:25:01.%N +0000
@@ -305,6 +305,15 @@
platform_device_register(&kirkwood_nand_flash);
}
+void __init kirkwood_nand_init_rnb(struct mtd_partition *parts, int nr_parts,
+ int (*dev_ready)(struct mtd_info *))
+{
+ kirkwood_clk_ctrl |= CGC_RUNIT;
+ kirkwood_nand_data.parts = parts;
+ kirkwood_nand_data.nr_parts = nr_parts;
+ kirkwood_nand_data.dev_ready = dev_ready;
+ platform_device_register(&kirkwood_nand_flash);
+}
/*****************************************************************************
* SoC RTC
Index: linux-2.6-2.6.32.9/arch/arm/mach-kirkwood/common.h
===================================================================
--- linux-2.6-2.6.32.9.orig/arch/arm/mach-kirkwood/common.h 2010-02-23 15:38:51.%N +0000
+++ linux-2.6-2.6.32.9/arch/arm/mach-kirkwood/common.h 2010-03-11 13:25:01.%N +0000
@@ -16,6 +16,7 @@
struct mv_sata_platform_data;
struct mvsdio_platform_data;
struct mtd_partition;
+struct mtd_info;
/*
* Basic Kirkwood init functions used early by machine-setup.
@@ -41,6 +42,7 @@
void kirkwood_uart0_init(void);
void kirkwood_uart1_init(void);
void kirkwood_nand_init(struct mtd_partition *parts, int nr_parts, int delay);
+void kirkwood_nand_init_rnb(struct mtd_partition *parts, int nr_parts, int (*dev_ready)(struct mtd_info *));
extern int kirkwood_tclk;
extern struct sys_timer kirkwood_timer;
next parent reply other threads:[~2010-04-29 23:12 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <20100429231136.086930268@fluff.org.uk>
2010-04-29 23:11 ` Ben Dooks [this message]
[not found] <20100429231253.465019575@fluff.org.uk>
2010-04-29 23:12 ` [patch 1/2] kirkwood: allow machines to register RnB line with mtd driver Ben Dooks
2010-05-05 5:55 ` Artem Bityutskiy
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20100429231204.169647403@fluff.org.uk \
--to=ben@simtec.co.uk \
--cc=linux-arm-kernel@lists.arm.linux.org.uk \
--cc=linux-mtd@lists.infradead.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).