Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754388AbcJKSFU (ORCPT ); Tue, 11 Oct 2016 14:05:20 -0400 Received: from smtprelay4.synopsys.com ([198.182.47.9]:41467 "EHLO smtprelay.synopsys.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752959AbcJKSFR (ORCPT ); Tue, 11 Oct 2016 14:05:17 -0400 From: Vineet Gupta Subject: Is conditional calling of restore_altstack() correct for ARC To: Al Viro CC: lkml , arcml , "linux-arch@vger.kernel.org" Message-ID: Date: Tue, 11 Oct 2016 11:04:41 -0700 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:45.0) Gecko/20100101 Thunderbird/45.3.0 MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 7bit X-Originating-IP: [10.10.161.29] Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 502 Lines: 15 Hi Al, I spotted a possible anomaly with ARC sigaltstack() handling and was wondering if you could confirm if it was wrong (I don't have a test case to prove one way or the other). We have a micro-optimization which elides calling restore_altstack() in sigreturn path, based on a "magic" value, set at the time of sigaction (SA_SIGINFO). So essentially we only restore ss_{sp,size,flags} if SA_SIGINFO was set. Do you think this needs to be done unconditionally like other ports do ? Thx, -Vineet