Re: [Xen-devel] [PATCH V4 1/9] block: add a helper function to read nr_setcs

2019-07-16 Thread Martin K. Petersen
Chaitanya, > This series just replaces the existing accesses without changing > anything. > > So if any of the exiting code has that bug then it will blow up > nicely. > > For future callers I don't mind adding a new check and resend the > series. > > Would you prefer adding a check ? I checked

Re: [Xen-devel] [PATCH V4 1/9] block: add a helper function to read nr_setcs

2019-07-12 Thread Chaitanya Kulkarni
On 7/11/19 6:59 PM, Martin K. Petersen wrote: > Hi Chaitanya, > >> +static inline sector_t bdev_nr_sects(struct block_device *bdev) >> +{ >> +return part_nr_sects_read(bdev->bd_part); >> +} > Can bdev end up being NULL in any of the call sites? > > Otherwise no objections. > Thanks for mentioni

Re: [Xen-devel] [PATCH V4 1/9] block: add a helper function to read nr_setcs

2019-07-11 Thread Martin K. Petersen
Hi Chaitanya, > +static inline sector_t bdev_nr_sects(struct block_device *bdev) > +{ > + return part_nr_sects_read(bdev->bd_part); > +} Can bdev end up being NULL in any of the call sites? Otherwise no objections. -- Martin K. Petersen Oracle Linux Engineering _