Skip to content

Commit 1e3fc20

Browse files
Dr. David Alan Gilbertaxboe
authored andcommitted
drbd: Remove unused conn_lowest_minor
conn_lowest_minor() last use was removed by 2011 commit 69a2277 ("drbd: Pass a peer device to a number of fuctions") Remove it. Signed-off-by: Dr. David Alan Gilbert <linux@treblig.org> Link: https://lore.kernel.org/r/20241010204426.277535-1-linux@treblig.org Reviewed-by: Christoph Hellwig <hch@lst.de> Signed-off-by: Jens Axboe <axboe@kernel.dk>
1 parent b402328 commit 1e3fc20

File tree

2 files changed

+0
-15
lines changed

2 files changed

+0
-15
lines changed

drivers/block/drbd/drbd_int.h

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1364,7 +1364,6 @@ extern struct bio_set drbd_io_bio_set;
13641364

13651365
extern struct mutex resources_mutex;
13661366

1367-
extern int conn_lowest_minor(struct drbd_connection *connection);
13681367
extern enum drbd_ret_code drbd_create_device(struct drbd_config_context *adm_ctx, unsigned int minor);
13691368
extern void drbd_destroy_device(struct kref *kref);
13701369
extern void drbd_delete_device(struct drbd_device *device);

drivers/block/drbd/drbd_main.c

Lines changed: 0 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -471,20 +471,6 @@ void _drbd_thread_stop(struct drbd_thread *thi, int restart, int wait)
471471
wait_for_completion(&thi->stop);
472472
}
473473

474-
int conn_lowest_minor(struct drbd_connection *connection)
475-
{
476-
struct drbd_peer_device *peer_device;
477-
int vnr = 0, minor = -1;
478-
479-
rcu_read_lock();
480-
peer_device = idr_get_next(&connection->peer_devices, &vnr);
481-
if (peer_device)
482-
minor = device_to_minor(peer_device->device);
483-
rcu_read_unlock();
484-
485-
return minor;
486-
}
487-
488474
#ifdef CONFIG_SMP
489475
/*
490476
* drbd_calc_cpu_mask() - Generate CPU masks, spread over all CPUs

0 commit comments

Comments
 (0)