From mboxrd@z Thu Jan 1 00:00:00 1970 From: Shinya Kuribayashi Date: Sat, 01 Oct 2011 12:59:20 +0900 Subject: [U-Boot] Is it necessary that uboot(mips) should read status register($12) before setting it In-Reply-To: References: Message-ID: <4E869018.6080102@pobox.com> List-Id: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: u-boot@lists.denx.de On 09/28/2011 06:09 PM, RdrouterUboot Router wrote: > 2.Is it right?I can delete this code "mfc0 $10,$12" from uboot. You can delete that MFC0 instruction in this case and save one word. Presumably the original code used to update the Status register value in read-modify-write manner, and at some point someone modified into current shape. By the way, since the first MIPS implementation of U-Boot was merged into the tree (by wdenk), we've been using k0($26) or t0($8) register as a scratch pad when modifying the Status register, while your example code uses t2($10). So it would be a custom U-Boot we don't know of.