From 9d175062d56972f082ce99753092b75419a228ce Mon Sep 17 00:00:00 2001 From: Jonathon Reinhart Date: Tue, 17 Sep 2024 15:32:25 +0000 Subject: [PATCH] pw_spi_mcuxpresso: Rename DoConfigure() to DoConfigureLocked() MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit This is to avoid confusion in a subsequent change. Change-Id: I9f503a458cdabb3d01fb4e50cd384e4ed04da0e9 Reviewed-on: https://pigweed-review.googlesource.com/c/pigweed/pigweed/+/236232 Commit-Queue: Jonathon Reinhart Lint: Lint 🤖 Docs-Not-Needed: Jonathon Reinhart Reviewed-by: Austin Foxley --- pw_spi_mcuxpresso/public/pw_spi_mcuxpresso/spi.h | 4 ++-- pw_spi_mcuxpresso/spi.cc | 8 ++++---- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/pw_spi_mcuxpresso/public/pw_spi_mcuxpresso/spi.h b/pw_spi_mcuxpresso/public/pw_spi_mcuxpresso/spi.h index 2d6a34a9e7..093af0e920 100644 --- a/pw_spi_mcuxpresso/public/pw_spi_mcuxpresso/spi.h +++ b/pw_spi_mcuxpresso/public/pw_spi_mcuxpresso/spi.h @@ -55,8 +55,8 @@ class McuxpressoInitiator : public Initiator { status_t status, void* context); - Status DoConfigure(const Config& config, - const std::lock_guard& lock); + Status DoConfigureLocked(const Config& config, + const std::lock_guard& lock); bool is_initialized() { return !!current_config_; } diff --git a/pw_spi_mcuxpresso/spi.cc b/pw_spi_mcuxpresso/spi.cc index 18fba1b419..7f331df6da 100644 --- a/pw_spi_mcuxpresso/spi.cc +++ b/pw_spi_mcuxpresso/spi.cc @@ -77,11 +77,11 @@ Status McuxpressoInitiator::Configure(const Config& config) { if (current_config_ && config == *current_config_) { return OkStatus(); } - return DoConfigure(config, lock); + return DoConfigureLocked(config, lock); } -Status McuxpressoInitiator::DoConfigure(const Config& config, - const std::lock_guard&) { +Status McuxpressoInitiator::DoConfigureLocked( + const Config& config, const std::lock_guard&) { spi_master_config_t master_config = {}; SPI_MasterGetDefaultConfig(&master_config); @@ -177,7 +177,7 @@ Status McuxpressoInitiator::SetChipSelect(uint32_t pin) { if (!current_config_) { return OkStatus(); } - return DoConfigure(*current_config_, lock); + return DoConfigureLocked(*current_config_, lock); } } // namespace pw::spi