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-next>] [day] [month] [year] [list]
Message-Id: <20221230194315.809903-1-t.schramm@manjaro.org>
Date:   Fri, 30 Dec 2022 20:43:14 +0100
From:   Tobias Schramm <t.schramm@...jaro.org>
To:     Ludovic Desroches <ludovic.desroches@...rochip.com>
Cc:     Ulf Hansson <ulf.hansson@...aro.org>,
        Nicolas Ferre <nicolas.ferre@...rochip.com>,
        Alexandre Belloni <alexandre.belloni@...tlin.com>,
        Claudiu Beznea <claudiu.beznea@...rochip.com>,
        linux-mmc@...r.kernel.org, linux-kernel@...r.kernel.org,
        Tobias Schramm <t.schramm@...jaro.org>
Subject: [PATCH 0/1] Fix race between stop command and start of next command in atmel-mci

Hey,

while using both slots on controller version 0x210 I noticed a race
condition in atmel-mci. When sending a stop command the command ready
interrupt is enabled before writing to the command register. This causes
the associated interrupt to fire immediately, making the state machine
believe that the stop command has completed already.
Usually this does not seem to cause a problem. I suspect the roudtrip of
mmc command completion through the kernel simply takes long enough that
the stop command has usually completed once a new command is queued.
However when using both slots a command might be queued for the other
slot already, causing immediate dispatch of that command to the
controller. This then interrupts the stop command still being sent and
also corrupts the new command.

I have only tested this patch with controller version 0x210, but from
documentation it seems like this should be a correct fix also for other
controller versions.

Cheers,
Tobias

Tobias Schramm (1):
  mmc: atmel-mci: fix race between stop command and start of next
    command

 drivers/mmc/host/atmel-mci.c | 3 ---
 1 file changed, 3 deletions(-)

-- 
2.30.2

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ