On 4/26/21 1:34 AM, Changheun Lee wrote: > Should we check queue point in bio_max_size()? > __device_add_disk() can be called with "register_queue=false" like as > device_add_disk_no_queue_reg(). How about below? > > unsigned int bio_max_size(struct bio *bio) > { > struct request_queue *q; > > q = (bio->bi_bdev) ? bio->bi_bdev->bd_disk->queue : NULL; > return q ? q->limits.bio_max_bytes : UINT_MAX; > } How could bio_max_size() get called from inside __device_add_disk() if no request queue is registered? Did I perhaps miss something? Thanks, Bart.