Skip to content

Commit 29ce182

Browse files
committed
Use "cookie" instead of "mask"
1 parent b4be231 commit 29ce182

File tree

3 files changed

+5
-5
lines changed

3 files changed

+5
-5
lines changed

ports/raspberrypi/audio_dma.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -400,10 +400,10 @@ uint32_t audio_dma_pause_all(void) {
400400
return result;
401401
}
402402

403-
void audio_dma_unpause_cookie(uint32_t cookie) {
403+
void audio_dma_unpause_mask(uint32_t mask) {
404404
for (size_t channel = 0; channel < NUM_DMA_CHANNELS; channel++) {
405405
audio_dma_t *dma = MP_STATE_PORT(playing_audio)[channel];
406-
if (dma != NULL && (cookie & (1 << channel))) {
406+
if (dma != NULL && (mask & (1 << channel))) {
407407
audio_dma_resume(dma);
408408
}
409409
}

ports/raspberrypi/audio_dma.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -90,6 +90,6 @@ void audio_dma_resume(audio_dma_t *dma);
9090
bool audio_dma_get_paused(audio_dma_t *dma);
9191

9292
uint32_t audio_dma_pause_all(void);
93-
void audio_dma_unpause_cookie(uint32_t cookie);
93+
void audio_dma_unpause_mask(uint32_t mask);
9494

9595
#endif // MICROPY_INCLUDED_RASPBERRYPI_AUDIO_DMA_OUT_H

ports/raspberrypi/supervisor/internal_flash.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -99,11 +99,11 @@ void port_internal_flash_flush(void) {
9999
// Make sure we don't have an interrupt while we do flash operations.
100100
common_hal_mcu_disable_interrupts();
101101
// and audio DMA must be paused as well
102-
uint32_t cookie = audio_dma_pause_all();
102+
uint32_t mask = audio_dma_pause_all();
103103
flash_range_erase(CIRCUITPY_CIRCUITPY_DRIVE_START_ADDR + _cache_lba, SECTOR_SIZE);
104104
flash_range_program(CIRCUITPY_CIRCUITPY_DRIVE_START_ADDR + _cache_lba, _cache, SECTOR_SIZE);
105105
_cache_lba = NO_CACHE;
106-
audio_dma_unpause_cookie(cookie);
106+
audio_dma_unpause_mask(mask);
107107
common_hal_mcu_enable_interrupts();
108108
}
109109

0 commit comments

Comments
 (0)