Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S932112AbbBLHKN (ORCPT ); Thu, 12 Feb 2015 02:10:13 -0500 Received: from smtprelay2.synopsys.com ([198.182.60.111]:33062 "EHLO smtprelay.synopsys.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750839AbbBLHKL convert rfc822-to-8bit (ORCPT ); Thu, 12 Feb 2015 02:10:11 -0500 From: Vineet Gupta To: "linux-arch@vger.kernel.org" , james Hogan CC: Alexey Brodkin , al Viro , lkml Subject: semantics of KSTK_ESP and friends Thread-Topic: semantics of KSTK_ESP and friends Thread-Index: AdBGku0BOnux0oi5SFiSwu7LnzmrjQ== Date: Thu, 12 Feb 2015 07:10:06 +0000 Message-ID: Accept-Language: en-US, en-IN Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-originating-ip: [10.12.196.223] Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 8BIT MIME-Version: 1.0 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 916 Lines: 20 Hi, Is KSTK_ESP supposed to return the kernel mode SP of a sleeping task or is it supposed to provide the user mode SP at the time of last kernel entry ? The 2 non arch users of the API expect the user mode SP semantics: * vm_is_stack_for_task() - to annotate /proc//maps stack vma - which is shere Alexey noted this. * do_task_stat() ARC port uses these for unwinding the task of a sleeping task (hence kernel mode SP semantics). metag (from the looks of it) also seem to provide kernel mode value, while most others seem to provide the user mode variant. I can fix ARC to work with expectation of generic code, but wanted to understand anyways. Thx, -Vineet -- 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/