New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix bug allowing SPI::abort_transfer to incorrectly unlock deep sleep mode #5722

Merged
merged 1 commit into from Jan 11, 2018

Conversation

Projects
None yet
6 participants
@scartmell-arm
Contributor

scartmell-arm commented Dec 18, 2017

Description

Fix bug allowing SPI::abort_transfer to incorrectly unlock deep sleep mode

  • Add flag to SPI class to track if the SPI instance has locked deep sleep mode.
  • Wrap call to sleep_manager_lock_deep_sleep to only be called if SPI instance
    hasn't already locked deep sleep.
  • Wrap call to sleep_manager_unlock_deep_sleep to only be called if SPI has
    currently locked deep sleep mode.

Status

READY

@0xc0170

I assume intention for lock/unclock deepsleep is protected by external means (SPI class is thread safe, thus deep sleep locking is already within already thread safe blocks in the implementation - _deep_sleep_locked is then protected). correct?

@0xc0170 0xc0170 requested review from c1728p9 and SenRamakri Dec 19, 2017

@scartmell-arm scartmell-arm force-pushed the scartmell-arm:bug-spi-abort-deep-sleep branch from 877a080 to 04cf0f2 Dec 20, 2017

@adbridge

This comment has been minimized.

Contributor

adbridge commented Jan 2, 2018

@c1728p9 @SenRamakri could you please review this?

@0xc0170

This comment has been minimized.

Member

0xc0170 commented Jan 2, 2018

@scartmell-arm Can you please rebase to get travis fix please?

@0xc0170 0xc0170 added needs: work and removed needs: review labels Jan 2, 2018

Fix bug allowing SPI::abort_transfer to incorrectly unlock deep sleep…
… mode

- Add flag to SPI class to track if the SPI instance has locked deep sleep mode.
- Wrap call to sleep_manager_lock_deep_sleep to only be called if SPI instance
  hasn't already locked deep sleep.
- Wrap call to sleep_manager_unlock_deep_sleep to only be called if SPI has
  currently locked deep sleep mode.

@scartmell-arm scartmell-arm force-pushed the scartmell-arm:bug-spi-abort-deep-sleep branch from 04cf0f2 to c267087 Jan 4, 2018

@scartmell-arm

This comment has been minimized.

Contributor

scartmell-arm commented Jan 8, 2018

/morph build

@mbed-ci

This comment has been minimized.

mbed-ci commented Jan 8, 2018

Build : SUCCESS

Build number : 820
Build artifacts/logs : http://mbed-os.s3-website-eu-west-1.amazonaws.com/?prefix=builds/5722/

Triggering tests

/morph test
/morph uvisor-test
/morph export-build

@theotherjimmy theotherjimmy added needs: CI and removed needs: work labels Jan 8, 2018

@mbed-ci

This comment has been minimized.

@mbed-ci

This comment has been minimized.

@cmonr cmonr merged commit f14ddd1 into ARMmbed:master Jan 11, 2018

18 checks passed

AWS-CI uVisor Build & Test Verification build successful.
Details
ci-morph-build build completed
Details
ci-morph-exporter build completed
Details
ci-morph-test test completed
Details
continuous-integration/jenkins/pr-head This commit looks good
Details
continuous-integration/travis-ci/pr The Travis CI build passed
Details
travis-ci/docs Local docs testing has passed
Details
travis-ci/events Local events testing has passed
Details
travis-ci/littlefs Local littlefs testing has passed
Details
travis-ci/mbed2-ATMEL Local mbed2-ATMEL testing has passed
Details
travis-ci/mbed2-MAXIM Local mbed2-MAXIM testing has passed
Details
travis-ci/mbed2-NORDIC Local mbed2-NORDIC testing has passed
Details
travis-ci/mbed2-NUVOTON Local mbed2-NUVOTON testing has passed
Details
travis-ci/mbed2-NXP Local mbed2-NXP testing has passed
Details
travis-ci/mbed2-RENESAS Local mbed2-RENESAS testing has passed
Details
travis-ci/mbed2-SILICON_LABS Local mbed2-SILICON_LABS testing has passed
Details
travis-ci/mbed2-STM Local mbed2-STM testing has passed
Details
travis-ci/tools Local tools testing has passed
Details

@cmonr cmonr removed the ready for merge label Jan 11, 2018

@scartmell-arm scartmell-arm deleted the scartmell-arm:bug-spi-abort-deep-sleep branch Dec 5, 2018

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