+-- On Mon, 5 Sep 2016, Paolo Bonzini wrote --+
| chunk_size should be uint32_t.
| 
| > -    while (data_length) {
| > -        while (!sg.resid) {
| > +    while (data_length && n < 2048) {
| > +        while (!sg.resid && n++ < 2048) {
| >              pvscsi_get_next_sg_elem(&sg);
| > -        assert(data_length > 0);
| > -        chunk_size = MIN((unsigned) data_length, sg.resid);
| > +        chunk_size = MIN(data_length, sg.resid);
| > Does this look okay?
| 
| Yes, just change 2048 to a #define PVSCSI_MAX_SG_ELEM.

  Done. I've sent a revised patch v2.

Thank you.
--
Prasad J Pandit / Red Hat Product Security Team
47AF CE69 3A90 54AA 9045 1053 DD13 3D32 FE5B 041F

Reply via email to