Add a small comment to explain why we need to start from
the end of the array to set the right prefered encoding.
Signed-off-by: Corentin Chary <[email protected]>
Signed-off-by: Anthony Liguori <[email protected]>
vs->tight_quality = 9;
vs->absolute = -1;
+ /*
+ * Start from the end because the encodings are sent in order of preference.
+ * This way the prefered encoding (first encoding defined in the array)
+ * will be set at the end of the loop.
+ */
for (i = n_encodings - 1; i >= 0; i--) {
enc = encodings[i];
switch (enc) {