Received: by 2002:a05:6a10:9848:0:0:0:0 with SMTP id x8csp2904029pxf; Sun, 28 Mar 2021 05:44:00 -0700 (PDT) X-Google-Smtp-Source: ABdhPJxCOXEm209P4yWrYw/M8rNc1/CuUkbATaMKLi7P4Cynh92WcJuIgGq4rks8s9pwW44snTWl X-Received: by 2002:a17:906:cb87:: with SMTP id mf7mr23708883ejb.81.1616935440263; Sun, 28 Mar 2021 05:44:00 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1616935440; cv=none; d=google.com; s=arc-20160816; b=MYvWxac+PymcvXAy3sedKQsvv8tP2vk/1hG628rOU1cdDjTlQQVBWZ6ZZTQL/niwYM gKlMqrnW117F8CUigFOeLA7m+V0T1QdqmJb/20zAg9Kx/wXTS0sTIJIH3y/R5gR9aNql GGNs6XOVWdIdUiBPiEXSarVlaVHbFu6/bh3JZyETFFfeV+jOjCN11Vg0F91UQSOhvgBQ G8PT8R+0wEKoapGVkxYJG/mymYWaufdpNKElRB1ubGZhR3lV4pW1LlvQH097ejhXDUZn V41cupxTvR145jdjtfJDet7zB+ZcpdVpEcnlsvjsVrh0dyq4TrWaPorGzuh7j1LvH2fE d/QA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-disposition:mime-version :references:message-id:subject:cc:to:from:date:dkim-signature; bh=wIfUfLS8WEjaD/bWCh93RNaDbRJK0LPFReTxH9coSJQ=; b=YY/rGEwfOvtyaTVPXnRlHQcZIp257H2//zxjB0AflGDMcNaiyx6WgTZpO97FRSzZ0D uIpodb6q/jAUPYo7T6X2CkfL/5JkadzTu54q9dzzNP066BkwlIv34RzkIB/iv8sFufLq jPb1Dd4wK9UTudxFUiw3PaSKEb99kGHGbUuCdIqM2gm3DKlqedlt76svKQrlRMH/BRQn NxYmd/b3V6P0xgqpcVSjQKZ7kYu/KA9VMSPkWr8o3fqlIGMhbRFERA6ZNnjkbFnxBkgr dUVeqdoxl7Qa8zX28ZZpn/s42VZz6qCOGOHFXn6i/Zh7ftfK08yD3aqq/7+bBomD/vn6 /bqQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=PqzFwpXW; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id kk8si11067730ejc.404.2021.03.28.05.43.37; Sun, 28 Mar 2021 05:44:00 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=PqzFwpXW; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229593AbhC1MkY (ORCPT + 99 others); Sun, 28 Mar 2021 08:40:24 -0400 Received: from mail.kernel.org ([198.145.29.99]:50770 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229499AbhC1MkF (ORCPT ); Sun, 28 Mar 2021 08:40:05 -0400 Received: by mail.kernel.org (Postfix) with ESMTPSA id 0A217600EF; Sun, 28 Mar 2021 12:40:03 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1616935205; bh=eu5d97hSMAWimAQeOp1i4JVeqM3czhuZjG/u5FMBSbQ=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=PqzFwpXWBsAshmGZg+OLXCEg2MqP1e9r33/GkjOzYfBHKg4OnWyotM9iFHVbHmzAM btPzRhVyq5ZK5MzJccv4E1xy6gDFcP4Ucr4zZdLd09acmjcENw/SKjs9+bLdIpuikS Az5aFkVoQtS53R6pNWNozfZXF5KTO/Fh/T/ze/eE= Date: Sun, 28 Mar 2021 14:40:02 +0200 From: Greg Kroah-Hartman To: Daniel Thompson Cc: Arnd Bergmann , Douglas Anderson , Jason Wessel , kgdb-bugreport@lists.sourceforge.net, linux-kernel@vger.kernel.org Subject: Re: [PATCH] kgdbts: Switch to do_sys_openat2() for breakpoint testing Message-ID: References: <20210325094807.3546702-1-daniel.thompson@linaro.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20210325094807.3546702-1-daniel.thompson@linaro.org> Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Thu, Mar 25, 2021 at 09:48:07AM +0000, Daniel Thompson wrote: > Currently kgdbts can get stuck waiting for do_sys_open() to be called > in some of the current tests. This is because C compilers often > automatically inline this function, which is a very thin wrapper around > do_sys_openat2(), into some of its callers. gcc-10 does this on (at least) > both x86 and arm64. > > We can fix the test suite by placing the breakpoints on do_sys_openat2() > instead since that isn't (currently) inlined. However do_sys_openat2() is > a static function so we cannot simply use an addressof. Since we are > testing debug machinery it is acceptable to use kallsyms to lookup a > suitable address because this is more or less what kdb does in the same > circumstances. Re-implement lookup_addr() to be based on kallsyms rather > than function pointers. > > Signed-off-by: Daniel Thompson > --- > > Notes: > So less than a week ago I said I had nothing pending for kgdbts. > That was entirely true when I said it... but then this came up. No worries, I'll take this too :) thanks, greg k-h