lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-Id: <20080915203835.E2438242E5@pipsqueak.localdomain>
Date:	Mon, 15 Sep 2008 13:38:35 -0700 (PDT)
From:	Roland McGrath <roland@...hat.com>
To:	Paul Mundt <lethal@...ux-sh.org>
Cc:	linux-arch@...r.kernel.org, utrace-devel@...hat.com,
	linux-kernel@...r.kernel.org
Subject: Re: CONFIG_HAVE_ARCH_TRACEHOOK and you

> user_stack_pointer() is apparently a requirement, too. 

Ah, yes!  I'd forgotten about user_stack_pointer() and instruction_pointer().
Those never got properly documented either.

> Although given that you already have a task_struct pointer the only place
> you currently use it (lib/syscall.c), it makes more sense to use
> KSTK_ESP/KSTK_EIP which is provided by almost everyone already.

Almost?  It must be everyone, right?  
It's used unconditionally in fs/proc/array.c (the only use).

I hadn't noticed these before.  They aren't commented anywhere.
I've got to say, too, these are truly dismal names!

Also, I've just noticed that x86-64's user_stack_pointer() is wrong for the
case when a fast-path 64-bit syscall is in progress.  To get it right, it
needs a bit from the struct thread_info, so a call that takes task_struct
instead of (or in addition to) pt_regs is certainly right.

These are defined in asm/processor.h, as macros.  It would be better if
they could be inlines, but they really can't because asm/processor.h is
before struct task_struct is defined, etc.  I wonder if we could move these
to another header where they can be clean inlines.  I'd sure like to change
those names while we're at it.

Thoughts?


Thanks,
Roland
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ