Skip to content

question about race condition in fat32lib SPI functions #1

Description

@steve-chamberlin

In the recvspiblock() function in fat32lib's sdhc.c, there's a comment saying "there is actually a race condition if an interrupt occurs here". Could you explain more about the potential race condition? I've looked at the code and don't see a problem - an interrupt would add some delay but wouldn't harm the SPI transfer as far as I can see. There's also a second comment about "double buffered" that I don't understand - is this referring to the hardware's automatic read data buffer? I started an AVR Freaks thread about these questions here: https://www.avrfreaks.net/s/topic/a5C3l000000UlCuEAK/t193130 Thanks!

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions