From: Helge Deller <deller@gmx.de>
To: Linus Torvalds <torvalds@linux-foundation.org>
Cc: Linux Kernel Mailing List <linux-kernel@vger.kernel.org>,
Parisc List <linux-parisc@vger.kernel.org>,
James Bottomley <James.Bottomley@hansenpartnership.com>
Subject: Re: [GIT PULL] parisc updates for v3.15
Date: Thu, 01 May 2014 23:55:14 +0200 [thread overview]
Message-ID: <5362C2C2.9040602@gmx.de> (raw)
In-Reply-To: <CA+55aFw+0_Wf+_2EAdi=OhVK3cZdMwsCV5cditaLz7LJroeByA@mail.gmail.com>
Hi Linus,
On 05/01/2014 09:23 PM, Linus Torvalds wrote:
> On Thu, May 1, 2014 at 11:38 AM, Helge Deller <deller@gmx.de> wrote:
>>
>> - Make mmap() behave similiar to other architectures: If a file hasn't been
>> mapped yet, we can now map it at any given page-aligned address.
>
> Ugh, so I pulled this, but I'm going to unpull it, because I dislike
> your new "i_mmap_lastmap" field.
>
> Now, the i_mmap_lastmap field itself, I could probably live with, but
> this change to generic code:
>
> + if (vma->vm_flags & VM_SHARED) {
> mapping->i_mmap_writable--;
> +#ifdef CONFIG_MMAP_TRACKING
> + if (mapping->i_mmap_writable == 0)
> + mapping->i_mmap_lastmmap = 0;
> +#endif
> + }
>
> makes me just gouge my eyes out. It's not only uglifying generic code,
> it's _stupid_ even when it's used.
>
> What's magic about "i_mmap_lastmmap" having the value zero? Nothing.
> Maybe somebody wants to map stuff at that zero value, and has the
> permissions to do so.
>
> So zeroing it is wrong. It's also entirely unnecessary, since you can
> just look at the "mapping->i_mmap_writable" value instead. So instead
> of checking "is i_mmap_lastmmap zero" as a way to check whether you
> can now use any virtual address, which is wrong _anyway_, you should
> have checked "is i_mmap_writable zero".
>
> Now, I *also* suspect that you could just get rid of i_mmap_lastmmap
> _entirely_, and instead just make "GET_LAST_MMAP()" just look up the
> first shared mapping it can find in the rb tree (if i_mmap_writable is
> non-null).
>
> But if it was just that one (unnecessary) field in the "struct
> address_space", I probably wouldn't mind, and say "ok, parisc has
> broken virtual caches, what else is new". But the fact that it adds
> code to the generic file just adds insult to injury and makes me go
> "no, I don't want to pull this".
>
> Mind fixing this? Here's a TOTALLY UNTESTED patch that may or may not
> work, but might at least act as a starting point.
I agree that this idea looks much better.
I will try to rewrite this code as you suggested (it sadly didn't worked out of the box).
But since it will take me some time, do you mind to pull in the other two remaining patches?
They fix a bug with GNU make on our debian build servers and I would like one of them to be backported into stable for 3.14...
Here is the *new* pull request (I dropped the patch above!):
Hi Linus,
please pull the latest parisc architecture fixes for kernel 3.15 from:
git://git.kernel.org/pub/scm/linux/kernel/git/deller/parisc-linux.git parisc-3.15-3
Those two patches drop the architecture-specifc value for_STK_LIM_MAX to
fix stack related problems with GNU make.
Thanks,
Helge
----------------------------------------------------------------
Helge Deller (1):
parisc: Use generic uapi/asm/resource.h file
John David Anglin (1):
parisc: remove _STK_LIM_MAX override
arch/parisc/include/uapi/asm/Kbuild | 3 ++-
arch/parisc/include/uapi/asm/resource.h | 7 -------
2 files changed, 2 insertions(+), 8 deletions(-)
delete mode 100644 arch/parisc/include/uapi/asm/resource.h
next prev parent reply other threads:[~2014-05-01 21:55 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-05-01 18:38 [GIT PULL] parisc updates for v3.15 Helge Deller
2014-05-01 19:23 ` Linus Torvalds
2014-05-01 21:55 ` Helge Deller [this message]
2014-05-01 22:56 ` Linus Torvalds
-- strict thread matches above, loose matches on Subject: below --
2014-05-16 20:01 Helge Deller
2014-04-17 19:07 Helge Deller
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=5362C2C2.9040602@gmx.de \
--to=deller@gmx.de \
--cc=James.Bottomley@hansenpartnership.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-parisc@vger.kernel.org \
--cc=torvalds@linux-foundation.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