Received: by 2002:ac0:a5a7:0:0:0:0:0 with SMTP id m36-v6csp6288965imm; Mon, 23 Jul 2018 15:10:26 -0700 (PDT) X-Google-Smtp-Source: AAOMgpfRQ2saoxZzNAR+qwWVMYg+Z1bVJ97nV6IUDegkYqRr+NN6nwupSh+Msb9BUBMJHF+XhDBk X-Received: by 2002:a17:902:22:: with SMTP id 31-v6mr14597383pla.332.1532383826262; Mon, 23 Jul 2018 15:10:26 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1532383826; cv=none; d=google.com; s=arc-20160816; b=pBuu4ty/vz1VKN5aEgo8LyowTv5+NDtH8H/yzM34Ui6K1sGDeYf0XW+7BP7efW2T+e qKgUH/F7BHaAR1RlSZ9Ml6fu5fijTbdf6GVfodEpw2ORr6AeWroRQXM6BWKwY2NtYBrr v17uO6nN34VckE3bGN1beWzo3BPOb7X7JrZbjLl6RXrlKZ/0qUWu75b4p1LvasxBFTT/ lDoNHrGbMMlGJf01J7q66GEIuIwFs3JOJ3NfkT9tps8Z8iBsNdA6BTjL+8QKhE4eM6kV q9n/Sx07mTNJTzAnUGZ2WmveA4Eb657JyOCo3quSF7AsZhqbO7CbYvihqJaug80sQ0vD Fyzw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to :content-disposition:mime-version:references:message-id:subject:cc :to:from:date:dkim-signature:arc-authentication-results; bh=Ysg63dtrR5zXVNM1XeDRu/vIWLmKfI5yyeI33Vyn0qk=; b=gSMtFsN1v8/5DJw993BS/D2rLxkx5MTFnjfGpxNCVks/migj1JL+xpE9cSkTHYOiPc 5egIqJFj5R4yBOH/MWADShEweql8ipX7ZCu33L6/Lpm7bEQdsrwcBrcScTmWyD+4EZUY +j3D6ik/z5uxVtHsUAEEwRbFcvO8HFITQKpmcqbXhM+JtnSNmhsyqNkKNbF1daFS1VGi MtJBOtZMPQqwt/K9xFEdyVFjFnnef9uJFdk01MUp0MdXsH+6XzpgJ9Za509RzljOX2DE 9iHzqWJMvUclNYO+34+vl5Ef7uY+TrnSMGMFI+I/OVzaTGJz+yOVbn7pYsJ5SLuOKq3p ZIwA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@ziepe.ca header.s=google header.b=GHiv7SkR; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id 186-v6si10112288pff.270.2018.07.23.15.10.10; Mon, 23 Jul 2018 15:10:26 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@ziepe.ca header.s=google header.b=GHiv7SkR; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2388190AbeGWXLo (ORCPT + 99 others); Mon, 23 Jul 2018 19:11:44 -0400 Received: from mail-wm0-f65.google.com ([74.125.82.65]:56045 "EHLO mail-wm0-f65.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S2388105AbeGWXLn (ORCPT ); Mon, 23 Jul 2018 19:11:43 -0400 Received: by mail-wm0-f65.google.com with SMTP id f21-v6so554720wmc.5 for ; Mon, 23 Jul 2018 15:08:26 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ziepe.ca; s=google; h=date:from:to:cc:subject:message-id:references:mime-version :content-disposition:in-reply-to:user-agent; bh=Ysg63dtrR5zXVNM1XeDRu/vIWLmKfI5yyeI33Vyn0qk=; b=GHiv7SkRf5X3eDH2JDQD/7CW88wj+48qsY8hbFCTjz4lqkEOvwLfYFlup1ChnLxxmD PwhLA8ncwVbaLuVFR8n0i8fAqft9R2xGGr5pditqMy+vITF95TcU9NMEfpD3g9zMiTMU qJZ2f6+Ki2iDb7rmx2zIRmvzNJFpQBlQYASVwkGpyXmBNQ6u6vCEMhOLlQSVTW5Cqps9 +cIOZxLaqY0yuB8CkK0TkXCyE8rt5v4cxLgcr9xH4aRN/6wVyhibX54mTjY2b5yhUfqc DzduqGzLYaDY54wjnLx+Pulw0iaHnvs3B0P6HU13atrx3mYZilFMSVixrHtFG+dsKJW9 ec6w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-disposition:in-reply-to:user-agent; bh=Ysg63dtrR5zXVNM1XeDRu/vIWLmKfI5yyeI33Vyn0qk=; b=qB8Mhf3udqds5hHvYM3VO9Zxd5cjm0dIZ/u9OtiT/Kz+O+DK4LHWiBwCcc/8skw5Tt 1QsdFNwU6WWTGS4YGBcGWooE+na12I2aqeCMtuPKUtj0UuDx0rLYHHKNiXvZNYOZ1FXm lwQ+tp6WApY0IoNzUoTx+Gew1uiJcpTxHAZ8OhymDPUxt92vYE1D0tnrPZDHuMj6jlXO x8QYQglJn+S1I9CNoHDgDlsrtjgrggy+N5qhHVlsmaj8I2GhnUE0kikRJY60aD/QucJU 0yixJlJxRw9ckpv6URZSeVcd86nsDthMi65hLdb5yvsZwHuFh4ezf+k124XwRWYt4Qpo GH4Q== X-Gm-Message-State: AOUpUlFvDutGJm3Q+prWNJVnueXz0ZpOqM6G+J8xiIJVnIFtOnAkodsq 9vJWChxve1b24j3Kato/xMDugw== X-Received: by 2002:a1c:1509:: with SMTP id 9-v6mr372164wmv.142.1532383706040; Mon, 23 Jul 2018 15:08:26 -0700 (PDT) Received: from ziepe.ca (S010614cc2056d97f.ed.shawcable.net. [174.3.196.123]) by smtp.gmail.com with ESMTPSA id a13-v6sm11668886wrf.93.2018.07.23.15.08.25 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Mon, 23 Jul 2018 15:08:25 -0700 (PDT) Received: from jgg by mlx.ziepe.ca with local (Exim 4.86_2) (envelope-from ) id 1fhj0A-000831-3t; Mon, 23 Jul 2018 16:08:22 -0600 Date: Mon, 23 Jul 2018 16:08:22 -0600 From: Jason Gunthorpe To: Tadeusz Struk Cc: James Bottomley , Jarkko Sakkinen , linux-integrity@vger.kernel.org, linux-security-module@vger.kernel.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH] tpm: add support for partial reads Message-ID: <20180723220822.GJ532@ziepe.ca> References: <153201555276.20155.1352499992826895966.stgit@tstruk-mobl1.jf.intel.com> <20180723201956.GB26824@linux.intel.com> <1532380412.4112.22.camel@HansenPartnership.com> <7441b5ef-18d8-13aa-ef4d-40fe684c9218@intel.com> <20180723215620.GH532@ziepe.ca> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.5.24 (2015-08-30) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Mon, Jul 23, 2018 at 03:00:20PM -0700, Tadeusz Struk wrote: > On 07/23/2018 02:56 PM, Jason Gunthorpe wrote: > > The proposed patch doesn't clear the data_pending if the entire buffer > > is not consumed, so of course it is ABI breaking, that really isn't OK. > > The data_pending will be cleared by the timeout handler if the user doesn't > read the response fully before the timeout expires. The is the same situation > if the user would not read the response at all. That causes write() to fail with EBUSY NAK from me on breaking the ABI like this Jason