Messages in this thread | | | Date | Tue, 10 Feb 2009 09:46:39 +0200 | From | Artem Bityutskiy <> | Subject | Re: [PATCH] write-back: fix break condition |
| |
Andrew Morton wrote: >> >> - if (nr_to_write > 0) >> + if (nr_to_write > 0) { >> nr_to_write--; >> - else if (wbc->sync_mode == WB_SYNC_NONE) { >> - /* >> - * We stop writing back only if we are not >> - * doing integrity sync. In case of integrity >> - * sync we have to keep going because someone >> - * may be concurrently dirtying pages, and we >> - * might have synced a lot of newly appeared >> - * dirty pages, but have not synced all of the >> - * old dirty pages. >> - */ >> - done = 1; >> - break; >> + if (nr_to_write == 0 && wbc->sync_mode == WB_SYNC_NONE) { >> + /* >> + * We stop writing back only if we are not >> + * doing integrity sync. In case of integrity >> + * sync we have to keep going because someone >> + * may be concurrently dirtying pages, and we >> + * might have synced a lot of newly appeared >> + * dirty pages, but have not synced all of the >> + * old dirty pages. >> + */ >> + done = 1; >> + break; >> + } >> } >> >> if (wbc->nonblocking && bdi_write_congested(bdi)) { > > Artem, Nick, please check?
I have not tested it, but it looks OK to me.
-- Best Regards, Artem Bityutskiy (Артём Битюцкий) -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/
| |