Received: by 2002:a05:6a10:a852:0:0:0:0 with SMTP id d18csp758282pxy; Wed, 5 May 2021 13:10:34 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwyjGFNX51zYCVpb9D+Im9x7lexXtlvmGfjUCrt2RbbT9478urvubgoJSmImqZ/A2zPjTeE X-Received: by 2002:a17:90a:b78d:: with SMTP id m13mr13815004pjr.47.1620245434537; Wed, 05 May 2021 13:10:34 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1620245434; cv=none; d=google.com; s=arc-20160816; b=o1uL4hgxXcvW/hp1JWHhdZ0Lh2iNxHn/PbrvwlLXFSDfyvt8qfvwbbBrRjqo8N4gsb cDJTRxX+GBBdkNRVKPIaC9KqQ5J9+AO5lTgXHYFJLUQ0Oh2czTc4a0s+ungjOFt1/BB9 D0DtJ3Oktl/rkkq1qKDiRch4xP9AH4W0TJp90qQ+oBxP/HSOBQ7jaj0SKmoh7q6TXlvv /CRmgliYFFybz9XfHQGRMqt8KRsrf7jJaH4IE20/AFeXYQVRRExBgbBzhVy3s+ekSC7H kPK9hCZ/7EefuRuw2b4iZeStluUxvhSiJZTax8HXEdlgCs3ZtuLOE7NYbZzYerl8v3f8 ThGw== 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=S+sdQ2COjd/MbhkDwqhxZnEipcQZXTl8S8y+N1Ke0i8=; b=HwQ5IJ5ixyY9bz4gyw5aUg+hG155wa9xgJJih65sgMkQme0cadszBQXbRul2AGcmgP E5QJTxmtEMOANbE5K7dCTdWQLtt3mRnAfMSj6DDrIyElS9pth7mMqywE3lYgi7a5R0Vp 0RfX/9Gqf2NWmckMDYPwvqi+2inBbyQyq3hCBTalCcghxhZmZlVSm60/3QKkvAUxZHM2 xDWs2lljU4dVVnKzSCUSYHPf9ooa/7zpQWsnwojgcygX93voOND739yaqzCBq/k2nt96 PxmUie3FfJBywOUGh6Fa/z21gbdSkPn/c65MlcE+8F0t5aKE5B74Zi+PBNCByPdOTN2G xIOA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=OT9gM4AT; 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 c5si98410plc.286.2021.05.05.13.10.22; Wed, 05 May 2021 13:10:34 -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=OT9gM4AT; 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 S234064AbhEEQ11 (ORCPT + 99 others); Wed, 5 May 2021 12:27:27 -0400 Received: from mail.kernel.org ([198.145.29.99]:46076 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234044AbhEEQ1W (ORCPT ); Wed, 5 May 2021 12:27:22 -0400 Received: by mail.kernel.org (Postfix) with ESMTPSA id C3A146121F; Wed, 5 May 2021 16:26:25 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1620231986; bh=+XVmn+qQ0hZ/pDYHrA4fm3voToW9efhwPKJClQ2Ns7o=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=OT9gM4ATRF7EKC10IJ4fI+H7Hqsj1wvNtM7A7lBUYC/s8V341V0eUabPn2xPEMNRA drpNeXq16PcBGH+kQLUd4WwVtWlG4M5jviIBP6Je28TSOZM10RWhPUHstVOt/E9O8I f5Cgti962c5HE7yDC44oA4xy6LmGunCM/OWjN2Dg= Date: Wed, 5 May 2021 18:26:24 +0200 From: Greg KH To: Jason Gunthorpe Cc: Nathan Chancellor , Kees Cook , Doug Ledford , Leon Romanovsky , Parav Pandit , Sami Tolvanen , linux-rdma@vger.kernel.org, linux-kernel@vger.kernel.org, clang-built-linux@googlegroups.com Subject: Re: CFI violation in drivers/infiniband/core/sysfs.c Message-ID: References: <20210402195241.gahc5w25gezluw7p@archlinux-ax161> <202104021555.08B883C7@keescook> <20210403065559.5vebyyx2p5uej5nw@archlinux-ax161> <20210504202222.GB2047089@ziepe.ca> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20210504202222.GB2047089@ziepe.ca> Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue, May 04, 2021 at 05:22:22PM -0300, Jason Gunthorpe wrote: > On Fri, Apr 02, 2021 at 11:55:59PM -0700, Nathan Chancellor wrote: > > > So, I think, the solution is below. This hasn't been runtime tested. It > > > basically removes the ib_port callback prototype and leaves everything > > > as kobject/attr. The callbacks then do their own container_of() calls. > > > > Well that appear to be okay from a runtime perspective. > > This giant thing should fix it, and some of the other stuff Greg observed: > > https://github.com/jgunthorpe/linux/commits/rmda_sysfs_cleanup > > It needs some testing before it gets posted When you post it, can you cc: me? thanks, greg k-h