[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <20160307160359.c8cde2e7cc4a52234f212c0d@linux-foundation.org>
Date: Mon, 7 Mar 2016 16:03:59 -0800
From: Andrew Morton <akpm@...ux-foundation.org>
To: Jan Stancek <jstancek@...hat.com>
Cc: linux-mm@...ck.org, linux-kernel@...r.kernel.org,
n-horiguchi@...jp.nec.com, mike kravetz <mike.kravetz@...cle.com>,
hillf zj <hillf.zj@...baba-inc.com>,
kirill shutemov <kirill.shutemov@...ux.intel.com>,
dave hansen <dave.hansen@...ux.intel.com>,
paul gortmaker <paul.gortmaker@...driver.com>
Subject: Re: [PATCH] mm/hugetlb: use EOPNOTSUPP in hugetlb sysctl handlers
On Sat, 5 Mar 2016 03:09:50 -0500 (EST) Jan Stancek <jstancek@...hat.com> wrote:
> > > Replace ENOTSUPP with EOPNOTSUPP. If hugepages are not supported,
> > > this value is propagated to userspace. EOPNOTSUPP is part of uapi
> > > and is widely supported by libc libraries.
> >
> > hm, what is the actual user-visible effect of this change? Does it fix
> > some misbehaviour?
> >
>
> It gives nicer message to user, rather than:
> # cat /proc/sys/vm/nr_hugepages
> cat: /proc/sys/vm/nr_hugepages: Unknown error 524
>
> And also LTP's proc01 test was failing because this ret code (524)
> was unexpected:
> proc01 1 TFAIL : proc01.c:396: read failed: /proc/sys/vm/nr_hugepages: errno=???(524): Unknown error 524
> proc01 2 TFAIL : proc01.c:396: read failed: /proc/sys/vm/nr_hugepages_mempolicy: errno=???(524): Unknown error 524
> proc01 3 TFAIL : proc01.c:396: read failed: /proc/sys/vm/nr_overcommit_hugepages: errno=???(524): Unknown error 524
>
Ah, OK, thanks. "Unknown error 524" is rather rude. I'll queue this
for 4.5.
Powered by blists - more mailing lists