lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:   Thu, 20 Apr 2017 10:12:41 -0700
From:   David Daney <ddaney@...iumnetworks.com>
To:     "Steven J. Hill" <Steven.Hill@...ium.com>,
        Ulf Hansson <ulf.hansson@...aro.org>,
        Jan Glauber <jan.glauber@...iumnetworks.com>
Cc:     linux-mmc <linux-mmc@...r.kernel.org>,
        "linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>,
        David Daney <david.daney@...ium.com>
Subject: Re: MMC block addressing mode.

On 04/20/2017 09:17 AM, Steven J. Hill wrote:
> On 04/20/2017 09:18 AM, Ulf Hansson wrote:
>>>
>>> The Cavium hardware requires knowledge of the card addressing mode.
>>> We need to either restore mmc_card_blockaddr(), or create another
>>> way to generate the same information. You previously suggested use
>>> of the 'blksz' value, however, it has the same value regardless of
>>> the card capacity. What would you suggest? Cheers.
>>
>> Right. Can you explain what the Cavium hardware need it for?
>>
> Uffe,
> 
> In Cavium's MMC controller, the DMA engine requires software to
> specify the addressing mode of the card. For DMA write operations,
> the CARD_ADDR field in the MIO_EMM_DMA register is programmed with
> a byte address if the media card <= 2GB. If the card is > 2GB, the
> address is interpreted as a 512 byte sector address. The SECTOR bit
> tells the controller how to interpret the address in CARD_ADDR. If
> set to 1, use 512 byte sector addressing, otherwise it is set to 0
> and byte addressing is used.
> 

... In other words:

The Cavium MMC controller doesn't directly send the commands supplied by 
the MMC core to the target device.  The driver analyzes the intent of 
the commands, and then programs the MMC bus interface unit to synthesize 
an equivalent, but perhaps different, set of commands to the target 
device.  As part of this synthesis, hardware needs to be told if sector 
or byte addressing is used by the target device.

Steven and Jan:  Can we get around this requirement by:

   - Always set MIO_EMM_DMA[MULTI] = 1;  This way by SECTOR mode may be 
unimportant.

   - Always set MIO_EMM_DMA[SECTOR] = SUITABLE_CONSTANT.

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ