From: Dongsheng Yang <yangds.fnst@cn.fujitsu.com>
To: Joe Perches <joe@perches.com>
Cc: linux-kernel@vger.kernel.org, fweisbec@gmail.com,
rostedt@goodmis.org, peterz@infradead.org, mingo@redhat.com
Subject: Re: [PATCH] kernel/sys: Replace hardcoding of 20 with MAX_NICE + 1
Date: Tue, 11 Mar 2014 10:35:08 +0800 [thread overview]
Message-ID: <531E765C.7060102@cn.fujitsu.com> (raw)
In-Reply-To: <1394504465.21085.27.camel@joe-AO722>
On 03/11/2014 10:21 AM, Joe Perches wrote:
> On Tue, 2014-03-11 at 09:17 +0800, Dongsheng Yang wrote:
>> Hi Joe,
>>
>> On 03/11/2014 06:23 AM, Joe Perches wrote:
>>> Convert the use of 20 to NICE_MAX + 1.
>> What about adding a macro in prio.h to convert nice value [19,-20] to
>> rlimit
>> style value [1,40]?
>>
>> It seems that it will be used in several places.
> Fine by me. knock yourself out.
>
> You might also consider changing these:
Yeah, my original plan is changing them from kernel/* to include/* then
to other subsystem such as driver, as I think I need to send them to
different
ML and different maintainers. But I think it is time to complete it now,
and we should make these changes go into tip tree.
So I will send a patch set for them.
- Dongsheng
>
> $ git grep -n -w -E "19|20"|grep -P "_nice" -i
> drivers/block/loop.c:551: set_user_nice(current, -20);
> drivers/block/nbd.c:536: set_user_nice(current, -20);
> drivers/block/pktcdvd.c:1466: set_user_nice(current, -20);
> drivers/char/ipmi/ipmi_si_intf.c:1001: set_user_nice(current, 19);
> drivers/s390/crypto/ap_bus.c:1806: set_user_nice(current, 19);
> drivers/scsi/bnx2fc/bnx2fc_fcoe.c:467: set_user_nice(current, -20);
> drivers/scsi/bnx2fc/bnx2fc_fcoe.c:605: set_user_nice(current, -20);
> drivers/scsi/bnx2i/bnx2i_hwi.c:1873: set_user_nice(current, -20);
> drivers/scsi/fcoe/fcoe.c:1875: set_user_nice(current, -20);
> drivers/scsi/ibmvscsi/ibmvfc.c:4518: set_user_nice(current, -20);
> drivers/scsi/ibmvscsi/ibmvscsi.c:2216: set_user_nice(current, -20);
> drivers/scsi/lpfc/lpfc_hbadisc.c:736: set_user_nice(current, -20);
> drivers/scsi/qla2xxx/qla_os.c:4759: set_user_nice(current, -20);
> drivers/staging/android/binder.c:439: min_nice = 20 - current->signal->rlim[RLIMIT_NICE].rlim_cur;
> drivers/staging/android/binder.c:444: if (min_nice < 20)
> drivers/staging/lustre/lustre/llite/lloop.c:410: set_user_nice(current, -20);
> fs/ocfs2/cluster/heartbeat.c:1110: set_user_nice(current, -20);
> include/linux/ioprio.h:55: return (task_nice(task) + 20) / 5;
> include/linux/sched/prio.h:4:#define MAX_NICE 19
> include/linux/sched/prio.h:5:#define MIN_NICE -20
> kernel/locking/locktorture.c:219: set_user_nice(current, 19);
> kernel/sys.c:253: niceval = 20 - task_nice(p);
> kernel/sys.c:264: niceval = 20 - task_nice(p);
> kernel/sys.c:280: niceval = 20 - task_nice(p);
> kernel/workqueue.c:105: RESCUER_NICE_LEVEL = -20,
> kernel/workqueue.c:106: HIGHPRI_NICE_LEVEL = -20,
> tools/testing/selftests/mqueue/mq_perf_tests.c:532: cur_nice = -20;
>
>
> --
> To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at http://vger.kernel.org/majordomo-info.html
> Please read the FAQ at http://www.tux.org/lkml/
>
next prev parent reply other threads:[~2014-03-11 3:00 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-03-05 12:36 [PATCH 1/3] tracing: Use inline task_nice() to get rid of an open coded implementation of it Dongsheng Yang
2014-03-05 12:36 ` [PATCH 2/3] sched: Use clamp() and clamp_val() to make it more readable Dongsheng Yang
2014-03-05 15:17 ` Joe Perches
2014-03-05 15:26 ` Steven Rostedt
2014-03-05 15:29 ` Joe Perches
2014-03-05 12:36 ` [PATCH 3/3] sched/prio: Replace hardcoding of 40 with NICE_WIDTH Dongsheng Yang
2014-03-10 22:23 ` [PATCH] kernel/sys: Replace hardcoding of 20 with MAX_NICE + 1 Joe Perches
2014-03-11 1:17 ` Dongsheng Yang
2014-03-11 2:21 ` Joe Perches
2014-03-11 2:35 ` Dongsheng Yang [this message]
2014-03-11 5:04 ` [PATCH 1/3] tracing: Use inline task_nice() to get rid of an open coded implementation of it Dongsheng Yang
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=531E765C.7060102@cn.fujitsu.com \
--to=yangds.fnst@cn.fujitsu.com \
--cc=fweisbec@gmail.com \
--cc=joe@perches.com \
--cc=linux-kernel@vger.kernel.org \
--cc=mingo@redhat.com \
--cc=peterz@infradead.org \
--cc=rostedt@goodmis.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox