History

swiotlb: use wrap_area_index() instead of open-coding it

No functional change, just use an existing helper.

Petr Tesarik committed 3 years ago

Commit 39e7d2a1 parent 7c3940b1 file · +1 −4Browse files

Unified · Split

kernel/dma/swiotlb.c+1−4
@@ -695,10 +695,7 @@ found: · 694 unmodified lines
695 /*695 /*
696 * Update the indices to avoid searching in the next round.696 * Update the indices to avoid searching in the next round.
697 */697 */
698 if (index + nslots < mem->area_nslabs)698 area->index = wrap_area_index(mem, index + nslots);
699 area->index = index + nslots;
700 else
701 area->index = 0;
702 area->used += nslots;699 area->used += nslots;
703 spin_unlock_irqrestore(&area->lock, flags);700 spin_unlock_irqrestore(&area->lock, flags);
704 return slot_index;701 return slot_index;

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t