summaryrefslogtreecommitdiff
path: root/packages
diff options
context:
space:
mode:
authorPaul Sokolovsky <pmiscml@gmail.com>2007-07-05 00:34:12 +0000
committerPaul Sokolovsky <pmiscml@gmail.com>2007-07-05 00:34:12 +0000
commita678820b7afaf0b93cd8949c689112bd723e755c (patch)
treea2cdeeda3175b3d94c36c58dd9d19e1e3317de2a /packages
parent0e9be06e62d9bfc3a2bfb79848cd6d27a07fc56b (diff)
parent70d0e263039165834e23471bdf0f860c46d68c31 (diff)
merge of '6f99be19e645cdee7ca3a6e76af76764e4c2140c'
and 'f2bd31f1aaf84bef9625b425a458bc019b97a434'
Diffstat (limited to 'packages')
-rw-r--r--packages/0xFFFF/0xffff-native_0.2.bb2
-rw-r--r--packages/0xFFFF/0xffff.inc2
-rw-r--r--packages/arm-kernel-shim/arm-kernel-shim_1.5.bb5
-rw-r--r--packages/arm-kernel-shim/files/config-fsg3.h2
-rw-r--r--packages/atk/atk_1.19.3.bb10
-rw-r--r--packages/gpephone/xoo-vm_0.7-20070204.bb4
-rw-r--r--packages/gtkmm/gtkmm.inc3
-rw-r--r--packages/kazehakase/kazehakase_0.4.5.bb2
-rw-r--r--packages/kazehakase/kazehakase_0.4.7.bb2
-rw-r--r--packages/kazehakase/kazehakase_cvs.bb18
-rw-r--r--packages/linux/linux-rp-2.6.21/locomo_spi-r4.patch947
-rw-r--r--packages/linux/linux-rp-2.6.21/sharpsl_pm-r1.patch213
-rw-r--r--packages/linux/linux-rp_2.6.21.bb24
-rw-r--r--packages/linux/linux-x86-2.6.20/i486-defconfig256
-rw-r--r--packages/linux/linux-x86_2.6.20.bb11
-rw-r--r--packages/linux/linux.inc2
-rw-r--r--packages/linux/linux/sarge-at91/.mtn2git_empty0
-rw-r--r--packages/linux/linux/sarge-at91/2.6.21-sarge-kernel.patch238
-rw-r--r--packages/linux/linux/sarge-at91/2.6.21-sarge-mmc.patch87
-rw-r--r--packages/linux/linux/sarge-at91/2.6.21-sarge-phy.patch400
-rw-r--r--packages/linux/linux/sarge-at91/defconfig1909
-rw-r--r--packages/linux/linux_2.6.21.bb6
-rw-r--r--packages/meta/meta-sdk-gpe.bb45
-rw-r--r--packages/meta/meta-sdk.bb38
-rw-r--r--packages/modutils/modutils-cross_2.4.27.bb2
-rw-r--r--packages/modutils/modutils_2.4.27.bb3
-rw-r--r--packages/php/php_5.1.4.bb2
-rw-r--r--packages/php/php_5.2.0.bb2
-rw-r--r--packages/qemu/qemu-native.inc2
-rw-r--r--packages/slugos-init/files/boot/kexec202
-rw-r--r--packages/slugos-init/files/boot/network5
-rw-r--r--packages/slugos-init/files/functions2
-rw-r--r--packages/slugos-init/files/modulefunctions9
-rw-r--r--packages/slugos-init/slugos-init_0.10.bb5
-rw-r--r--packages/tasks/task-opie-all.bb7
-rw-r--r--packages/tasks/task-slugos.bb6
-rw-r--r--packages/uboot/u-boot-1.1.6/sarge-uboot.patch3326
-rw-r--r--packages/uboot/u-boot_1.1.6.bb6
-rw-r--r--packages/uclibc/files/errno_values.h.patch21
-rw-r--r--packages/uclibc/files/termios.h.patch22
-rw-r--r--packages/uclibc/uclibc_0.9.29.bb8
-rw-r--r--packages/uicmoc/uicmoc-native-2.3.10/kernel-asm-page.patch20
-rw-r--r--packages/uicmoc/uicmoc-native_2.3.10.bb5
43 files changed, 7731 insertions, 150 deletions
diff --git a/packages/0xFFFF/0xffff-native_0.2.bb b/packages/0xFFFF/0xffff-native_0.2.bb
index b709977179..1cee49aafd 100644
--- a/packages/0xFFFF/0xffff-native_0.2.bb
+++ b/packages/0xFFFF/0xffff-native_0.2.bb
@@ -1,5 +1,7 @@
require 0xffff.inc
+DEPENDS = "libusb-native"
+
inherit native
do_stage() {
diff --git a/packages/0xFFFF/0xffff.inc b/packages/0xFFFF/0xffff.inc
index 470db7ccbf..db281467ed 100644
--- a/packages/0xFFFF/0xffff.inc
+++ b/packages/0xFFFF/0xffff.inc
@@ -1,5 +1,5 @@
DESCRIPTION = "The 'Open Free Fiasco Firmware Flasher' aka 0xFFFF utility aims to implement a free (GPL'd) userspace handler for the NOLO bootloader."
-LICENSE = "GPLv2"
+LICENSE = "GPLv3"
SRC_URI = "http://www.nopcode.org/0xFFFF/get/0xFFFF-${PV}.tar.gz"
diff --git a/packages/arm-kernel-shim/arm-kernel-shim_1.5.bb b/packages/arm-kernel-shim/arm-kernel-shim_1.5.bb
index 0788f81609..9e2b6fd912 100644
--- a/packages/arm-kernel-shim/arm-kernel-shim_1.5.bb
+++ b/packages/arm-kernel-shim/arm-kernel-shim_1.5.bb
@@ -3,7 +3,7 @@ SECTION = ""
PRIORITY = "optional"
HOMEPAGE = "http://wiki.buici.com/twiki/bin/view/Main/ApexBootloader"
LICENSE = "GPL"
-PR = "r1"
+PR = "r2"
COMPATIBLE_MACHINE = "(ixp4xx|nslu2)"
@@ -20,7 +20,7 @@ CMDLINE_CONSOLE = "console=${@bb.data.getVar("KERNEL_CONSOLE",d,1) or "ttyS0"}"
CMDLINE_ROOT_DSMG600 = "root=/dev/mtdblock2 rootfstype=jffs2 rw init=/linuxrc"
CMDLINE_ROOT_NAS100D = "root=/dev/mtdblock2 rootfstype=jffs2 rw init=/linuxrc"
CMDLINE_ROOT_NSLU2 = "root=/dev/mtdblock4 rootfstype=jffs2 rw init=/linuxrc"
-CMDLINE_ROOT_FSG3 = "root=/dev/mtdblock2 rootfstype=jffs2 rw init=/linuxrc"
+# CMDLINE is passed correctly on the Freecom FSG-3 from the bootloader.
EXTRA_OEMAKE_append = " CROSS_COMPILE=${CROSS_DIR}/bin/${HOST_PREFIX}"
@@ -70,7 +70,6 @@ oe_runmake() {
sed -e 's|//#define FORCE_LITTLEENDIAN|#define FORCE_LITTLEENDIAN|' \
${WORKDIR}/config-fsg3.h > ${S}/config.h
fi
- echo "#define COMMANDLINE \"${CMDLINE_CONSOLE} ${CMDLINE_ROOT_FSG3} ${CMDLINE_DEBUG}\"" >> ${S}/config.h
rm -f ${S}/main.o
oenote make ${PARALLEL_MAKE} CROSS_COMPILE=${CROSS_DIR}/bin/${TARGET_PREFIX} PACKAGE=arm-kernel-shim-fsg3
make ${PARALLEL_MAKE} CROSS_COMPILE=${CROSS_DIR}/bin/${TARGET_PREFIX} PACKAGE=arm-kernel-shim-fsg3 || die "oe_runmake failed"
diff --git a/packages/arm-kernel-shim/files/config-fsg3.h b/packages/arm-kernel-shim/files/config-fsg3.h
index 9b88462e89..fa894e89ac 100644
--- a/packages/arm-kernel-shim/files/config-fsg3.h
+++ b/packages/arm-kernel-shim/files/config-fsg3.h
@@ -21,8 +21,6 @@
#define MACH_TYPE 1091
-#define CREATE_ATAGS
-
/* Uncomment one of these to switch the CPU into a specific mode. */
//#define FORCE_LITTLEENDIAN
//#define FORCE_BIGENDIAN
diff --git a/packages/atk/atk_1.19.3.bb b/packages/atk/atk_1.19.3.bb
new file mode 100644
index 0000000000..beef4ce97a
--- /dev/null
+++ b/packages/atk/atk_1.19.3.bb
@@ -0,0 +1,10 @@
+require atk.inc
+
+DEFAULT_PREFERENCE = "-1"
+
+SRC_URI = "ftp://ftp.gnome.org/pub/GNOME/sources/atk/1.19/atk-${PV}.tar.bz2"
+
+do_stage () {
+ oe_libinstall -so -C atk libatk-1.0 ${STAGING_LIBDIR}
+ autotools_stage_includes
+}
diff --git a/packages/gpephone/xoo-vm_0.7-20070204.bb b/packages/gpephone/xoo-vm_0.7-20070204.bb
index b927269db2..0bdda47359 100644
--- a/packages/gpephone/xoo-vm_0.7-20070204.bb
+++ b/packages/gpephone/xoo-vm_0.7-20070204.bb
@@ -6,7 +6,7 @@ LICENSE = "GPL"
DEPENDS = "virtual/libx11 libxtst gtk+ libglade"
SRCDATE = 20070204
PV = "0.7+svn${SRCDATE}"
-PR = "r2"
+PR = "r3"
SRC_URI = "svn://svn.o-hand.com/repos/matchbox/trunk;module=Xoo;proto=http \
file://gpephone-vm.patch;patch=1;pnum=0"
@@ -14,3 +14,5 @@ SRC_URI = "svn://svn.o-hand.com/repos/matchbox/trunk;module=Xoo;proto=http \
S = "${WORKDIR}/Xoo"
inherit autotools
+
+FILES_${PN} += "${datadir}/xoo"
diff --git a/packages/gtkmm/gtkmm.inc b/packages/gtkmm/gtkmm.inc
index b99bf9b395..9dd1e43d54 100644
--- a/packages/gtkmm/gtkmm.inc
+++ b/packages/gtkmm/gtkmm.inc
@@ -3,8 +3,7 @@ HOMEPAGE = "http://www.gtkmm.org/"
SECTION = "libs"
PRIORITY = "optional"
LICENSE = "LGPL"
-DEPENDS = "atk glibmm gtk+"
-PR = "r0"
+DEPENDS = "atk glibmm gtk+ cairomm"
inherit gnome autotools pkgconfig flow-lossage
diff --git a/packages/kazehakase/kazehakase_0.4.5.bb b/packages/kazehakase/kazehakase_0.4.5.bb
index 494e19bad9..927699318e 100644
--- a/packages/kazehakase/kazehakase_0.4.5.bb
+++ b/packages/kazehakase/kazehakase_0.4.5.bb
@@ -7,5 +7,3 @@ SRC_URI = "http://osdn.dl.sourceforge.jp/kazehakase/24791/kazehakase-${PV}.tar.g
inherit autotools pkgconfig
-DEFAULT_PREFERENCE = "-1"
-
diff --git a/packages/kazehakase/kazehakase_0.4.7.bb b/packages/kazehakase/kazehakase_0.4.7.bb
index 70e99a40fb..9b30ce918d 100644
--- a/packages/kazehakase/kazehakase_0.4.7.bb
+++ b/packages/kazehakase/kazehakase_0.4.7.bb
@@ -7,5 +7,3 @@ SRC_URI = "http://iij.dl.sourceforge.jp/kazehakase/25610/kazehakase-${PV}.tar.gz
inherit autotools pkgconfig
-DEFAULT_PREFERENCE = "-1"
-
diff --git a/packages/kazehakase/kazehakase_cvs.bb b/packages/kazehakase/kazehakase_cvs.bb
new file mode 100644
index 0000000000..c0a26d01ea
--- /dev/null
+++ b/packages/kazehakase/kazehakase_cvs.bb
@@ -0,0 +1,18 @@
+DESCRIPTION = "A gtk-webcore based browser"
+HOMEPAGE = "http://kazehakase.sourceforge.jp/"
+SECTION = "x11/network"
+LICENSE = "GPLv2"
+DEPENDS = "osb-nrcit glib-2.0"
+
+SRC_URI = "cvs://anonymous@cvs.sourceforge.jp/cvsroot/kazehakase;module=kazehakase"
+S = "${WORKDIR}/kazehakase"
+
+
+PV = "0.4.7+cvs${SRCDATE}"
+
+inherit autotools pkgconfig
+
+EXTRA_OECONF = " --disable-gtkmozembed "
+
+DEFAULT_PREFERENCE = "-1"
+
diff --git a/packages/linux/linux-rp-2.6.21/locomo_spi-r4.patch b/packages/linux/linux-rp-2.6.21/locomo_spi-r4.patch
new file mode 100644
index 0000000000..7ecc48f956
--- /dev/null
+++ b/packages/linux/linux-rp-2.6.21/locomo_spi-r4.patch
@@ -0,0 +1,947 @@
+Index: linux-2.6.21/drivers/spi/Kconfig
+===================================================================
+--- linux-2.6.21.orig/drivers/spi/Kconfig 2007-04-26 05:08:32.000000000 +0200
++++ linux-2.6.21/drivers/spi/Kconfig 2007-07-03 21:40:52.000000000 +0200
+@@ -89,6 +89,10 @@
+ This enables using the Freescale iMX SPI controller in master
+ mode.
+
++config SPI_LOCOMO
++ tristate "Locomo SPI master"
++ depends on SPI_MASTER && SHARP_LOCOMO && EXPERIMENTAL
++
+ config SPI_MPC83xx
+ tristate "Freescale MPC83xx SPI controller"
+ depends on SPI_MASTER && PPC_83xx && EXPERIMENTAL
+Index: linux-2.6.21/drivers/spi/locomo_spi.c
+===================================================================
+--- /dev/null 1970-01-01 00:00:00.000000000 +0000
++++ linux-2.6.21/drivers/spi/locomo_spi.c 2007-07-03 21:40:52.000000000 +0200
+@@ -0,0 +1,873 @@
++#include <asm/io.h>
++#include <asm/irq.h>
++#include <linux/module.h>
++#include <linux/init.h>
++#include <linux/device.h>
++#include <linux/stat.h>
++#include <linux/delay.h>
++#include <linux/interrupt.h>
++#include <asm/hardware/locomo.h>
++#include <linux/mmc/host.h>
++#include <linux/spi/spi.h>
++#include <linux/spi/mmc_spi.h>
++#include <linux/workqueue.h>
++#include <linux/spinlock.h>
++#include <linux/list.h>
++#include "locomo_spi.h"
++static struct locomospi_dev * spidev;
++static struct work_struct transfer_wq;
++int verbose=0;
++/* MMC_SPI functions *********************************************************/
++
++static int locomommcspi_init(struct device *dev, irqreturn_t (*isr)(int, void*), void *mmc)
++{
++ int result;
++ locomo_gpio_set_irq(spidev->ldev->dev.parent, LOCOMO_GPIO_CARD_DETECT, LOCOMO_GPIO_IRQ_ON_RISE | LOCOMO_GPIO_IRQ_ON_FALL);
++ spidev->mmc_spi_isr = isr;
++ result=request_irq(IRQ_LOCOMO_CARDDETECT, locomospi_cardisr, SA_SHIRQ, "locomo-spi", mmc);
++ return result;
++}
++
++static void locomommcspi_exit(struct device *dev, void* mmc)
++{
++ free_irq(IRQ_LOCOMO_CARDDETECT, mmc);
++}
++
++static int locomommcspi_getro(struct device *dev)
++{
++ return locomo_gpio_read_level(spidev->ldev->dev.parent,LOCOMO_GPIO_WRITE_PROTECT) > 0 ? 1 : 0;
++}
++
++static void locomommcspi_powermode(struct device *dev, unsigned char mode)
++{
++ if(mode == MMC_POWER_OFF && spidev->card_power != 0)
++ locomospi_power(0);
++ else if( spidev->card_power != 1)
++ locomospi_power(1);
++
++}
++
++static void locomommcspi_reset(void)
++{
++ /* transmit card reset sequence, should be done from mmc_layer */
++ locomospi_setcs(1);
++ tx("\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff",10);
++ locomospi_setcs(0);
++}
++
++
++static struct mmc_spi_platform_data colliemmc ={
++ .init = locomommcspi_init,
++ .exit = locomommcspi_exit,
++ .detect_delay = HZ,
++ .get_ro = locomommcspi_getro,
++ .ocr_mask = MMC_VDD_32_33 | MMC_VDD_33_34,
++ .setpowermode = locomommcspi_powermode,
++ .reset = locomommcspi_reset,
++};
++
++/* Utility function **********************************************************/
++
++static irqreturn_t locomospi_cardisr(int irq, void *dev_id)
++{
++ u16 r;
++ if(locomospi_carddetect()){
++ r = locomo_readl(spidev->base+LOCOMO_SPIMD);
++ r |= 0x80;
++ locomo_writel( r, spidev->base+LOCOMO_SPIMD);
++ r = locomo_readl(spidev->base+LOCOMO_SPIMD);
++ r |= 0x40;
++ locomo_writel( r, spidev->base+LOCOMO_SPIMD);
++ /* transmit card reset sequence, should be done from mmc_layer */
++// locomospi_setcs(1);
++ // tx("\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff",10);
++// locomospi_setcs(0);
++ } else {
++ r = locomo_readl(spidev->base+LOCOMO_SPIMD);
++ r &= ~0x80;
++ locomo_writel( r, spidev->base+LOCOMO_SPIMD);
++ r = locomo_readl(spidev->base+LOCOMO_SPIMD);
++ r &= ~0x40;
++ locomo_writel( r, spidev->base+LOCOMO_SPIMD);
++ }
++ return spidev->mmc_spi_isr(irq, dev_id);
++}
++
++static void locomospi_power(int on)
++{
++ locomo_gpio_write(spidev->ldev->dev.parent, LOCOMO_GPIO_CARD_POWER, on);
++ spidev->card_power=on;
++ set_current_state(TASK_INTERRUPTIBLE);
++ if(on){
++ schedule_timeout(HZ/10);
++ } else {
++ schedule_timeout(2*HZ);
++ }
++
++}
++
++static void locomospi_setclock(unsigned int base, unsigned int mult)
++{
++ u16 r = locomo_readl(spidev->base+LOCOMO_SPIMD);
++ base &= 0x7;
++ mult &= 0x3;
++ r &= ~(0x7 | 0x18 | 0x40);
++ locomo_writel(r,spidev->base+LOCOMO_SPIMD);
++ r |= (base | (mult <<3) | 0x40);
++ locomo_writel(r,spidev->base+LOCOMO_SPIMD);
++ spidev->clock_base = base;
++ spidev->clock_mult = mult;
++
++}
++// returns 1 if card ist present, 0 otherwise
++static int locomospi_carddetect()
++{
++ return (locomo_gpio_read_level(spidev->ldev->dev.parent,LOCOMO_GPIO_CARD_DETECT)>0)?0:1;
++}
++
++static void locomospi_togglecs()
++{
++ u16 r;
++ r = locomo_readl(spidev->base + LOCOMO_SPICT);
++ r ^= 0x40; // I think this is CHIPSELECTHIGH
++ locomo_writel(r, spidev->base + LOCOMO_SPICT);
++}
++
++static void locomospi_setcs(int high)
++{
++ u16 r;
++ r = locomo_readl(spidev->base + LOCOMO_SPICT);
++ if(high)
++ r |= 0x40;
++ else
++ r &= ~0x40;
++ locomo_writel(r, spidev->base + LOCOMO_SPICT);
++}
++
++static void locomospi_reg_open()
++{
++ u16 r;
++ spidev->clock_base = 4;
++ spidev->clock_mult = 0;
++ locomospi_power(1);
++ locomo_writel( 0x6c00 | (2 <<3)|4, spidev->base+LOCOMO_SPIMD);
++ if(locomospi_carddetect()){
++ r = locomo_readl(spidev->base+LOCOMO_SPIMD);
++ r |= 0x80;
++ locomo_writel( r, spidev->base+LOCOMO_SPIMD);
++ r = locomo_readl(spidev->base+LOCOMO_SPIMD);
++ r |= 0x40;
++ locomo_writel( r, spidev->base+LOCOMO_SPIMD);
++ }
++ locomo_writel( 0x40, spidev->base+LOCOMO_SPICT);
++ r = locomo_readl(spidev->base+LOCOMO_SPICT);
++ r |= 0x80;
++ locomo_writel( r, spidev->base+LOCOMO_SPICT);
++ udelay(200);
++ r = locomo_readl(spidev->base+LOCOMO_SPICT);
++ locomo_writel(r, spidev->base+LOCOMO_SPICT);
++ r = locomo_readl(spidev->base+LOCOMO_SPICT);
++ r |= 0x1;
++ locomo_writel(r, spidev->base+LOCOMO_SPICT);
++ r = locomo_readl(spidev->base+LOCOMO_SPICT);
++ r &= ~0x40;
++ locomo_writel(r, spidev->base+LOCOMO_SPICT);
++}
++
++static void locomospi_reg_release()
++{
++ u16 r;
++ r = locomo_readl(spidev->base+LOCOMO_SPICT);
++ r &= ~0x80;
++ locomo_writel(r, spidev->base+LOCOMO_SPICT);
++ r = locomo_readl(spidev->base+LOCOMO_SPIMD);
++ r &= ~0x40;
++ locomo_writel(r, spidev->base+LOCOMO_SPIMD);
++ r = locomo_readl(spidev->base+LOCOMO_SPIMD);
++ r &= ~0x80;
++ locomo_writel(r, spidev->base+LOCOMO_SPIMD);
++ r = locomo_readl(spidev->base+LOCOMO_SPICT);
++ r |= 0x40;
++ locomo_writel(r, spidev->base+LOCOMO_SPICT);
++ locomospi_power(0);
++}
++
++static int tx(const char* buffer, int size)
++{
++ int i=0,j=0;
++// int result=0;
++ int wait;
++ if(!spidev->clock_base && !spidev->clock_mult)
++ return 0;
++ if(spidev->clock_base == 4)
++ wait = 0x10000;
++ else
++ wait = 8;
++
++ for(i=0; i<size; i++){
++/* if(!(locomo_readl(spidev->base+LOCOMO_SPIST) & LOCOMO_SPI_RFW)){
++ result = wait_event_interruptible(spidev->waitqueue, locomo_readl(spidev->base+LOCOMO_SPIST) & LOCOMO_SPI_RFW);
++ if(result) {
++ dev_err(&spidev->sdev->dev, "received Signal. giving up tx.");
++ return i;
++ }
++ }*/
++ for(j=0; j <= wait; j++){
++ if(locomo_readl(spidev->base+LOCOMO_SPIST) & LOCOMO_SPI_RFW)
++ break;
++ }
++ locomo_writel((u16) buffer[i], spidev->base+LOCOMO_SPITD);
++ if(verbose)
++ printk(KERN_DEBUG "locomospi: sent: char :%x\n", (u16) buffer[i]);
++ if(spidev->clock_base){
++ for(j=0; j <= wait; j++){
++ if(!(locomo_readl(spidev->base+LOCOMO_SPIST) & LOCOMO_SPI_RFW))
++ break;
++ }
++ }
++ }
++ if(spidev->clock_base){
++ for(i=0; i <= wait; i++){
++ if(locomo_readl(spidev->base+LOCOMO_SPIST) & LOCOMO_SPI_TEND)
++ break;
++ }
++ }
++ return j;
++}
++
++static int rx(char* buffer, int size)
++{
++ int i,j;
++// int result=0;
++ int wait;
++ u16 rd;
++ if(!spidev->clock_base && !spidev->clock_mult)
++ return 0;
++ if(spidev->clock_base == 4)
++ wait = 0x10000;
++ else
++ wait = 8;
++
++ for(i=0; i<size; i++){
++/* if(!(locomo_readl(spidev->base+LOCOMO_SPIST) & LOCOMO_SPI_RFW)){
++ result = wait_event_interruptible(spidev->waitqueue, locomo_readl(spidev->base+LOCOMO_SPIST) & LOCOMO_SPI_RFW);
++ if(result) {
++ dev_err(&spidev->sdev->dev, "received Signal. giving up tx.");
++ return i;
++ }
++ }*/
++ for(j=0; j <= wait; j++){
++ if(locomo_readl(spidev->base+LOCOMO_SPIST) & LOCOMO_SPI_RFR)
++ break;
++ }
++ rd= locomo_readl(spidev->base+LOCOMO_SPIRD);
++ if(verbose)
++ printk(KERN_DEBUG "locomospi: received: char :%x\n", (u16) buffer[i]);
++ buffer[i]=(char) rd;
++ if(spidev->clock_base){
++ for(j=0; j <= wait; j++){
++ if(!(locomo_readl(spidev->base+LOCOMO_SPIST) & LOCOMO_SPI_RFR))
++ break;
++ }
++ }
++ }
++ return i;
++}
++
++/*
++static irqreturn_t locomospi_rwready(int irq, void *dev_id)
++{
++ struct locomospi_dev* dev=(struct locomospi_dev*) dev_id;
++// dev_dbg(&spidev->sdev->dev, "IRQ: %d\n", irq);
++// printk(KERN_DEBUG "locomospi: IRQ: %d\n", irq);
++ wake_up_interruptible(&dev->waitqueue);
++ return IRQ_HANDLED;
++}
++
++static irqreturn_t locomospi_testisr(int irq, void *dev_id)
++{
++ char *buf="";
++ switch(irq){
++ case IRQ_LOCOMO_SPI_RFR: buf="RFR";
++ break;
++ case IRQ_LOCOMO_SPI_RFW: buf="RFW";
++ break;
++ case IRQ_LOCOMO_SPI_OVRN:buf="OVRN";
++ break;
++ case IRQ_LOCOMO_SPI_TEND:buf="TEND";
++ break;
++ case IRQ_LOCOMO_CARDDETECT:
++ buf="CARD_DETECT";
++ break;
++ default: return IRQ_NONE;
++ }
++ printk(KERN_DEBUG "locomospi: IRQ: %s\n",buf);
++// dev_dbg(&spidev->sdev->dev, "IRQ: %s\n",buf);
++ return IRQ_HANDLED;
++}
++*/
++/* sysfs attributes used for debug *******************************************/
++
++/* SPI registers */
++ssize_t locomospi_showspimd(struct device_driver *drv, char *buf)
++{
++ return sprintf(buf, "0x%x\n", locomo_readl(spidev->base+LOCOMO_SPIMD));
++}
++
++ssize_t locomospi_storespimd(struct device_driver *drv, const char *buf, size_t count)
++{
++ locomo_writel(simple_strtoul(buf, NULL, 16), spidev->base+LOCOMO_SPIMD);
++ return count;
++}
++static DRIVER_ATTR(spimd, S_IWUSR | S_IRUGO, locomospi_showspimd, locomospi_storespimd);
++
++ssize_t locomospi_showspict(struct device_driver *drv, char *buf)
++{
++ return sprintf(buf, "0x%x\n", locomo_readl(spidev->base+LOCOMO_SPICT));
++}
++
++ssize_t locomospi_storespict(struct device_driver *drv, const char *buf, size_t count)
++{
++ locomo_writel(simple_strtoul(buf, NULL, 16), spidev->base+LOCOMO_SPICT);
++ return count;
++}
++static DRIVER_ATTR(spict, S_IWUSR | S_IRUGO, locomospi_showspict, locomospi_storespict);
++
++ssize_t locomospi_showspist(struct device_driver *drv, char *buf)
++{
++ return sprintf(buf, "0x%x\n", locomo_readl(spidev->base+LOCOMO_SPIST));
++}
++
++ssize_t locomospi_storespist(struct device_driver *drv, const char *buf, size_t count)
++{
++ locomo_writel(simple_strtoul(buf, NULL, 16), spidev->base+LOCOMO_SPIST);
++ return count;
++}
++static DRIVER_ATTR(spist, S_IWUSR | S_IRUGO, locomospi_showspist, locomospi_storespist);
++
++ssize_t locomospi_showspiis(struct device_driver *drv, char *buf)
++{
++ return sprintf(buf, "0x%x\n", locomo_readl(spidev->base+LOCOMO_SPIIS));
++}
++
++ssize_t locomospi_storespiis(struct device_driver *drv, const char *buf, size_t count)
++{
++ locomo_writel(simple_strtoul(buf, NULL, 16), spidev->base+LOCOMO_SPIIS);
++ return count;
++}
++static DRIVER_ATTR(spiis, S_IWUSR | S_IRUGO, locomospi_showspiis, locomospi_storespiis);
++
++ssize_t locomospi_showspiwe(struct device_driver *drv, char *buf)
++{
++ return sprintf(buf, "0x%x\n", locomo_readl(spidev->base+LOCOMO_SPIWE));
++}
++
++ssize_t locomospi_storespiwe(struct device_driver *drv, const char *buf, size_t count)
++{
++ locomo_writel(simple_strtoul(buf, NULL, 16), spidev->base+LOCOMO_SPIWE);
++ return count;
++}
++static DRIVER_ATTR(spiwe, S_IWUSR | S_IRUGO, locomospi_showspiwe, locomospi_storespiwe);
++
++ssize_t locomospi_showspiie(struct device_driver *drv, char *buf)
++{
++ return sprintf(buf, "0x%x\n", locomo_readl(spidev->base+LOCOMO_SPIIE));
++}
++
++ssize_t locomospi_storespiie(struct device_driver *drv, const char *buf, size_t count)
++{
++ locomo_writel(simple_strtoul(buf, NULL, 16), spidev->base+LOCOMO_SPIIE);
++ return count;
++}
++static DRIVER_ATTR(spiie, S_IWUSR | S_IRUGO, locomospi_showspiie, locomospi_storespiie);
++
++ssize_t locomospi_showspiir(struct device_driver *drv, char *buf)
++{
++ return sprintf(buf, "0x%x\n", locomo_readl(spidev->base+LOCOMO_SPIIR));
++}
++
++ssize_t locomospi_storespiir(struct device_driver *drv, const char *buf, size_t count)
++{
++ locomo_writel(simple_strtoul(buf, NULL, 16), spidev->base+LOCOMO_SPIIR);
++ return count;
++}
++static DRIVER_ATTR(spiir, S_IWUSR | S_IRUGO, locomospi_showspiir, locomospi_storespiir);
++
++ssize_t locomospi_showspitd(struct device_driver *drv, char *buf)
++{
++ return sprintf(buf, "0x%x\n", locomo_readl(spidev->base+LOCOMO_SPITD));
++}
++
++ssize_t locomospi_storespitd(struct device_driver *drv, const char *buf, size_t count)
++{
++ locomo_writel(simple_strtoul(buf, NULL, 16), spidev->base+LOCOMO_SPITD);
++ return count;
++}
++static DRIVER_ATTR(spitd, S_IWUSR | S_IRUGO, locomospi_showspitd, locomospi_storespitd);
++
++ssize_t locomospi_showspird(struct device_driver *drv, char *buf)
++{
++ return sprintf(buf, "0x%x\n", locomo_readl(spidev->base+LOCOMO_SPIRD));
++}
++
++ssize_t locomospi_storespird(struct device_driver *drv, const char *buf, size_t count)
++{
++ locomo_writel(simple_strtoul(buf, NULL, 16), spidev->base+LOCOMO_SPIRD);
++ return count;
++}
++static DRIVER_ATTR(spird, S_IWUSR | S_IRUGO, locomospi_showspird, locomospi_storespird);
++
++ssize_t locomospi_showspits(struct device_driver *drv, char *buf)
++{
++ return sprintf(buf, "0x%x\n", locomo_readl(spidev->base+LOCOMO_SPITS));
++}
++
++ssize_t locomospi_storespits(struct device_driver *drv, const char *buf, size_t count)
++{
++ locomo_writel(simple_strtoul(buf, NULL, 16), spidev->base+LOCOMO_SPITS);
++ return count;
++}
++static DRIVER_ATTR(spits, S_IWUSR | S_IRUGO, locomospi_showspits, locomospi_storespits);
++
++ssize_t locomospi_showspirs(struct device_driver *drv, char *buf)
++{
++ return sprintf(buf, "0x%x\n", locomo_readl(spidev->base+LOCOMO_SPIRS));
++}
++
++ssize_t locomospi_storespirs(struct device_driver *drv, const char *buf, size_t count)
++{
++ locomo_writel(simple_strtoul(buf, NULL, 16), spidev->base+LOCOMO_SPIRS);
++ return count;
++}
++static DRIVER_ATTR(spirs, S_IWUSR | S_IRUGO, locomospi_showspirs, locomospi_storespirs);
++
++/* MMC Card status */
++
++ssize_t locomospi_showpower(struct device_driver *drv, char *buf)
++{
++ return sprintf(buf, "%d\n", spidev->card_power);
++}
++
++ssize_t locomospi_storepower(struct device_driver *drv, const char *buf, size_t count)
++{
++ locomospi_power(simple_strtoul(buf, NULL, 10));
++ return count;
++}
++static DRIVER_ATTR(cardpower, S_IWUSR | S_IRUGO, locomospi_showpower, locomospi_storepower);
++
++ssize_t locomospi_detectcard(struct device_driver *drv, char *buf)
++{
++ return sprintf(buf, "%d\n",(locomo_gpio_read_level(spidev->ldev->dev.parent,LOCOMO_GPIO_CARD_DETECT)>0)?0:1);
++}
++static DRIVER_ATTR(carddetect, S_IRUGO, locomospi_detectcard, NULL);
++
++ssize_t locomospi_writeprotect(struct device_driver *drv, char *buf)
++{
++ return sprintf(buf, "%d\n",(locomo_gpio_read_level(spidev->ldev->dev.parent,LOCOMO_GPIO_WRITE_PROTECT)>0)?1:0);
++}
++static DRIVER_ATTR(cardwriteprotect, S_IRUGO, locomospi_writeprotect, NULL);
++
++ssize_t locomospi_showclockbase(struct device_driver *drv, char *buf)
++{
++ return sprintf(buf, "%d\n", spidev->clock_base);
++}
++
++ssize_t locomospi_storeclockbase(struct device_