From mboxrd@z Thu Jan 1 00:00:00 1970 From: Amit Virdi Date: Mon, 26 Mar 2012 16:53:27 +0530 Subject: [U-Boot] [PATCH 03/25] SPEAr: Place ethaddr write and read within CONFIG_CMD_NET In-Reply-To: <201203071421.08705.sr@denx.de> References: <1331121854-20494-1-git-send-email-amit.virdi@st.com> <1331121854-20494-4-git-send-email-amit.virdi@st.com> <201203071421.08705.sr@denx.de> Message-ID: <4F7051AF.9080905@st.com> List-Id: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: u-boot@lists.denx.de Hi Stefan, Sorry for this delayed response, I'm back to office after almost 2 weeks. On 3/7/2012 6:51 PM, Stefan Roese wrote: > On Wednesday 07 March 2012 13:03:52 Amit Virdi wrote: >> From: Vipin KUMAR >> >> ethaddr can be optionally read from i2c memory. So, chip_config command >> supports reading/writing hw mac id into i2c memory. Placing this code >> within CONFIG_CMD_NET as this would only be needed when network interface >> is configured >> >> Signed-off-by: Vipin Kumar >> Signed-off-by: Amit Virdi > > I'm not really sure, why you have this special ethaddr handling in I2C prom > here at all. Isn't it enough to have the MAC address (ethaddr) stored in the > U-Boot environment (NOR, NAND, etc)? Why do you need this additional I2C > stuff? Could you please explain this? > Generally MAC addresses are stored in EEPROMs due to two reasons: 1. Special set of command sequences are required to erase data from an EEPROM 2. EEPROMs are cheaper As a result, board manufacturers provide an EEPROM memory that contains MAC address and other vital board parameters. In such case, NAND/NOR memories may not have ethaddr stored. On SPEAr, I2C is used to access EEPROM. So this patch is required. Please let me know if I understood your question correctly and, hence, gave the right answer. Thanks n Regards Amit Virdi