public inbox for u-boot@lists.denx.de
 help / color / mirror / Atom feed
* [U-Boot] [U-BOOT][PATCH 1/3] mflash : Fix some style issue
@ 2009-02-17  7:10 unsik Kim
  2009-02-21 21:54 ` Wolfgang Denk
  0 siblings, 1 reply; 4+ messages in thread
From: unsik Kim @ 2009-02-17  7:10 UTC (permalink / raw)
  To: u-boot

Signed-off-by: unsik Kim <donari75@gmail.com>
---
  common/env_mgdisk.c     |    2 ++
  drivers/block/mg_disk.c |   13 +++++--------
  2 files changed, 7 insertions(+), 8 deletions(-)

diff --git a/common/env_mgdisk.c b/common/env_mgdisk.c
index 2b4949f..363ee68 100644
--- a/common/env_mgdisk.c
+++ b/common/env_mgdisk.c
@@ -72,11 +72,13 @@ OUT:
  int saveenv(void)
  {
  	unsigned int err;
+
  	env_ptr->crc = crc32(0, env_ptr->data, ENV_SIZE);
  	err = mg_disk_write(CONFIG_ENV_ADDR, (u_char *)env_ptr,
  			CONFIG_ENV_SIZE);
  	if (err)
  		puts ("*** Warning - mg_disk_write error\n\n");
+
  	return err;
  }

diff --git a/drivers/block/mg_disk.c b/drivers/block/mg_disk.c
index 193a441..9ae8889 100644
--- a/drivers/block/mg_disk.c
+++ b/drivers/block/mg_disk.c
@@ -28,8 +28,6 @@
  #include <asm/io.h>
  #include "mg_disk_prv.h"

-#ifdef CONFIG_CMD_MG_DISK
-
  #ifndef CONFIG_MG_DISK_RES
  #define CONFIG_MG_DISK_RES	0
  #endif
@@ -116,11 +114,11 @@ static void mg_ident_cpy (unsigned char *dst, unsigned char *src,
  		goto OUT;

  	/* skip leading white space */
-	while ((*src) && (src<end) && (*src==' '))
+	while ((*src) && (src < end) && (*src == ' '))
  		++src;

  	/* copy string, omitting trailing white space */
-	while ((*src) && (src<end)) {
+	while ((*src) && (src < end)) {
  		*dst++ = *src;
  		if (*src++ != ' ')
  			last = dst;
@@ -278,9 +276,9 @@ static unsigned int mg_out(unsigned int sect_num,
  {
  	u32 err = MG_ERR_NONE;

-	if ((err = mg_wait(MG_STAT_READY, 3000))) {
+	err = mg_wait(MG_STAT_READY, 3000);
+	if (err)
  		return err;
-	}

  	writeb((u8)sect_cnt, MG_BASE + MG_REG_SECT_CNT);
  	writeb((u8)sect_num, MG_BASE + MG_REG_SECT_NUM);
@@ -289,6 +287,7 @@ static unsigned int mg_out(unsigned int sect_num,
  	writeb((u8)((sect_num >> 24) | MG_REG_HEAD_LBA_MODE),
  		MG_BASE + MG_REG_DRV_HEAD);
  	writeb(cmd, MG_BASE + MG_REG_COMMAND);
+
  	return err;
  }

@@ -631,5 +630,3 @@ unsigned int mg_disk_init (void)

  	return err;
  }
-
-#endif /* CONFIG_CMD_MG_DISK */
-- 
1.5.6.6

^ permalink raw reply related	[flat|nested] 4+ messages in thread

* [U-Boot] [U-BOOT][PATCH 1/3] mflash : Fix some style issue
  2009-02-17  7:10 [U-Boot] [U-BOOT][PATCH 1/3] mflash : Fix some style issue unsik Kim
@ 2009-02-21 21:54 ` Wolfgang Denk
  2009-02-23  2:57   ` unsik Kim
  0 siblings, 1 reply; 4+ messages in thread
From: Wolfgang Denk @ 2009-02-21 21:54 UTC (permalink / raw)
  To: u-boot

Dear unsik Kim,

In message <499A62D9.1050807@gmail.com> you wrote:
> Signed-off-by: unsik Kim <donari75@gmail.com>
> ---
>   common/env_mgdisk.c     |    2 ++
>   drivers/block/mg_disk.c |   13 +++++--------
>   2 files changed, 7 insertions(+), 8 deletions(-)

Since your original patch did not make it in yet, it is probably best
when you squash and rebase your whole patch series, and resubmit then
Thanks.

Best regards,

Wolfgang Denk

-- 
DENX Software Engineering GmbH,     MD: Wolfgang Denk & Detlev Zundel
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: wd at denx.de
This is an unauthorized cybernetic announcement.

^ permalink raw reply	[flat|nested] 4+ messages in thread

* [U-Boot] [U-BOOT][PATCH 1/3] mflash : Fix some style issue
  2009-02-21 21:54 ` Wolfgang Denk
@ 2009-02-23  2:57   ` unsik Kim
  2009-04-03 21:45     ` Wolfgang Denk
  0 siblings, 1 reply; 4+ messages in thread
From: unsik Kim @ 2009-02-23  2:57 UTC (permalink / raw)
  To: u-boot

Hello?

I attached "all-in-one" rebased, squashed patch for your request.

Regards,

unsik Kim
-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: 0009-Initial-mflash-support.patch
Url: http://lists.denx.de/pipermail/u-boot/attachments/20090223/0670d328/attachment-0001.txt 

^ permalink raw reply	[flat|nested] 4+ messages in thread

* [U-Boot] [U-BOOT][PATCH 1/3] mflash : Fix some style issue
  2009-02-23  2:57   ` unsik Kim
@ 2009-04-03 21:45     ` Wolfgang Denk
  0 siblings, 0 replies; 4+ messages in thread
From: Wolfgang Denk @ 2009-04-03 21:45 UTC (permalink / raw)
  To: u-boot

Dear unsik Kim,

In message <49A210AC.3080605@gmail.com> you wrote:
>
> From 53292a06d57fcd93fa508c5c698bca5b60a19691 Mon Sep 17 00:00:00 2001
> From: unsik Kim <donari75@gmail.com>
> Date: Wed, 18 Feb 2009 14:31:49 +0900
> Subject: [PATCH 09/13] Initial mflash support
> 
> Mflash is fusion memory device mainly targeted consumer eletronic and
> mobile phone.
> Internally, it have nand flash and other hardware logics and supports
> some different operation (ATA, IO, XIP) modes.
> 
> IO mode is custom mode for the host that doesn't have IDE interface.
> (Many mobile targeted SoC doesn't have IDE bus)
> 
> This driver support mflash IO mode.
> 
> Followings are brief descriptions about IO mode.
> 
> 1. IO mode based on ATA protocol and uses some custom command. (read
> confirm, write confirm)
> 2. IO mode uses SRAM bus interface.
> 
> Signed-off-by: unsik Kim <donari75@gmail.com>
> ---
>  common/Makefile             |    2 +
>  common/cmd_mgdisk.c         |   76 ++++++
>  common/cmd_nvedit.c         |    8 +-
>  common/env_mgdisk.c         |   92 +++++++
>  disk/part.c                 |    8 +-
>  disk/part_amiga.c           |    5 +-
>  disk/part_dos.c             |    1 +
>  disk/part_efi.c             |    1 +
>  disk/part_iso.c             |    1 +
>  disk/part_mac.c             |    1 +
>  doc/README.mflash           |   94 +++++++
>  drivers/block/Makefile      |    5 +-
>  drivers/block/mg_disk.c     |  582 +++++++++++++++++++++++++++++++++++++++++++
>  drivers/block/mg_disk_prv.h |  145 +++++++++++
>  fs/fat/fat.c                |    2 +
>  include/config_cmd_all.h    |    1 +
>  include/environment.h       |   12 +
>  include/mg_disk.h           |   51 ++++
>  include/part.h              |    1 +
>  19 files changed, 1080 insertions(+), 8 deletions(-)
>  create mode 100644 common/cmd_mgdisk.c
>  create mode 100644 common/env_mgdisk.c
>  create mode 100644 doc/README.mflash
>  create mode 100644 drivers/block/mg_disk.c
>  create mode 100644 drivers/block/mg_disk_prv.h
>  create mode 100644 include/mg_disk.h

Applied, thanks.

Best regards,

Wolfgang Denk

-- 
DENX Software Engineering GmbH,     MD: Wolfgang Denk & Detlev Zundel
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: wd at denx.de
In a business, marketroids, salespukes, and  lawyers  have  different
goals from those who actually do work and produce something. Usually,
is  is the former who triumph over the latter, due to the simple rule
that those who print the money make the rules.
         -- Tom Christiansen in <5jdcls$b04$2@csnews.cs.colorado.edu>

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2009-04-03 21:45 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2009-02-17  7:10 [U-Boot] [U-BOOT][PATCH 1/3] mflash : Fix some style issue unsik Kim
2009-02-21 21:54 ` Wolfgang Denk
2009-02-23  2:57   ` unsik Kim
2009-04-03 21:45     ` Wolfgang Denk

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox