public inbox for u-boot@lists.denx.de
 help / color / mirror / Atom feed
From: Ilko Iliev <iliev@ronetix.at>
To: u-boot@lists.denx.de
Subject: [U-Boot] [PATCH] mtd/dataflash.c: fix a problem with the last partition
Date: Wed, 22 Oct 2008 15:11:13 +0200	[thread overview]
Message-ID: <48FF2671.7090608@ronetix.at> (raw)

This patch fix the problem that only the [NB_DATAFLASH_AREA -1] 
dataflash partition  can be defined to use the area to the end of 
dataflash size.
Now it is possible to have only one dataflash partition from 0 to the 
end of of dataflash size.

Signed-off-by: Ilko Iliev <iliev@ronetix.at>


index 201e518..43746e7 100644
--- a/drivers/mtd/dataflash.c
+++ b/drivers/mtd/dataflash.c
@@ -131,7 +131,7 @@ int AT91F_DataflashInit (void)
                        break;
                }
                /* set the last area end to the dataflash size*/
-               area_list[NB_DATAFLASH_AREA -1].end =
+               dataflash_info[i].end_address =
                                (dataflash_info[i].Device.pages_number *
                                dataflash_info[i].Device.pages_size)-1;

@@ -146,7 +146,7 @@ int AT91F_DataflashInit (void)
                                if(area_list[part].end == 0xffffffff) {
                                        
dataflash_info[i].Device.area_list[j].end =
                                                
dataflash_info[i].end_address +
-                                               dataflash_info  
[i].logical_address;
+                                               
dataflash_info[i].logical_address;
                                        last_part = 1;
                                } else {
                                        
dataflash_info[i].Device.area_list[j].end =


-- 
Mit freundlichen Gr??en/With best regards,
Ilko Iliev
Ronetix Development Tools GmbH
CPU Modules, JTAG/BDM Emulators and Flash Programmers
Waidhausenstrasse 13/5, 1140 Vienna, Austria
E-Mail: iliev at ronetix.at; Web: www.ronetix.at

             reply	other threads:[~2008-10-22 13:11 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-10-22 13:11 Ilko Iliev [this message]
2008-10-27 14:30 ` [U-Boot] [PATCH] mtd/dataflash.c: fix a problem with the last partition Jean-Christophe PLAGNIOL-VILLARD
2008-10-27 15:46   ` Ilko Iliev
  -- strict thread matches above, loose matches on Subject: below --
2008-12-02 16:27 Ilko Iliev
2008-12-02 21:06 ` Jean-Christophe PLAGNIOL-VILLARD

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=48FF2671.7090608@ronetix.at \
    --to=iliev@ronetix.at \
    --cc=u-boot@lists.denx.de \
    /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