Commit f1b3a6ec authored by Philipp Reisner's avatar Philipp Reisner
Browse files

drbd: Consolidated the setup of the thread name into the framework

parent a21e9298
Loading
Loading
Loading
Loading
+3 −0
Original line number Diff line number Diff line
@@ -446,6 +446,9 @@ static int drbd_thread_setup(void *arg)
	unsigned long flags;
	int retval;

	snprintf(current->comm, sizeof(current->comm), "drbd_%c_%s",
		 thi->name[0], thi->mdev->tconn->name);

restart:
	retval = thi->function(thi);

+0 −5
Original line number Diff line number Diff line
@@ -4227,11 +4227,8 @@ static int drbd_do_auth(struct drbd_tconn *tconn)
int drbdd_init(struct drbd_thread *thi)
{
	struct drbd_conf *mdev = thi->mdev;
	unsigned int minor = mdev_to_minor(mdev);
	int h;

	sprintf(current->comm, "drbd%d_receiver", minor);

	dev_info(DEV, "receiver (re)started\n");

	do {
@@ -4572,8 +4569,6 @@ int drbd_asender(struct drbd_thread *thi)
	int ping_timeout_active = 0;
	int empty;

	sprintf(current->comm, "drbd%d_asender", mdev_to_minor(mdev));

	current->policy = SCHED_RR;  /* Make this a realtime task! */
	current->rt_priority = 2;    /* more important than all other tasks */

+0 −2
Original line number Diff line number Diff line
@@ -1631,8 +1631,6 @@ int drbd_worker(struct drbd_thread *thi)
	LIST_HEAD(work_list);
	int intr = 0, i;

	sprintf(current->comm, "drbd%d_worker", mdev_to_minor(mdev));

	while (get_t_state(thi) == RUNNING) {
		drbd_thread_current_set_cpu(thi);