Received: by 10.213.65.68 with SMTP id h4csp1778367imn; Mon, 19 Mar 2018 13:01:50 -0700 (PDT) X-Google-Smtp-Source: AG47ELvMcm1u7VU1pfAYr2im8LkPeh6pM0JcRMA/1ML1TjYmwSw18EtO5Al5llb7pL25PBY4b3vC X-Received: by 2002:a17:902:20e5:: with SMTP id v34-v6mr13975950plg.66.1521489710031; Mon, 19 Mar 2018 13:01:50 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1521489709; cv=none; d=google.com; s=arc-20160816; b=L2A+bDoQPTNIrdxqhMO2ofBDqzZP9ZcSdrC47Q9HZIp4ilxFBn7Wr37uy2gmPpPGMF XP/53Bp0VVKM7pcKyZ+R/2bb4iDGTMF84q4qwC7V1NhGMGjQquU9T8IAuk5YkDqTWoO+ Nr4dVvuyFZrDFxJmZlF7AfVhMPzx0xf6MSDKL2MyAPEn6N+L0aiqNCLI7ni3jhreWPhp 0MB0Q0TrEgaVurXs95bfuFFnh9axsVl8cr2uXSJRyAwJl+e0H4C15HpqLy3Z1h/pSJFJ IU5qfnD21wxf02+RW+8rXn5PiLk8CnCRr42O+QYBVt3mdZK0Bi8Y62rwRTvMTmEHBGYJ h30Q== 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:arc-authentication-results; bh=8b+iseeVVUCk3+X9kAu0AnEU+BekPJNaLqawus+XSRA=; b=lQ4tCP27KV/cmZMn0/3KGYiD4IczhvOrClVASZz6DUetoX7EvBZ6zUmFaFnV/UsfHl QIWXuHqQv9WHaHaKhO7WKuofKtNbCQ87C4zL7tVzK/dF+wsnU1ujkQyi4NWK8rLzDf1I KJVSYN9o/yN9+LXKmTq3j8vQqvPQWtSwvl9asJrMOTDPnbC+H2MI0hZxgC2uAuDmpLFc xMeZkREvlS3n6Q5QMTEB2MunUjLpxo6gC8XZAC0AYX4XCp4Z04W35wcyOdNDIC1D735I WQMMtk+cMNzvRTYkSJUamAjZUhGZsJNCojSBao6rvAUdho4f1+THQapRVodswze1VHDR b+5Q== ARC-Authentication-Results: i=1; mx.google.com; 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 p2-v6si542410pll.304.2018.03.19.13.01.34; Mon, 19 Mar 2018 13:01:49 -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; 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 S970537AbeCST7y (ORCPT + 99 others); Mon, 19 Mar 2018 15:59:54 -0400 Received: from verein.lst.de ([213.95.11.211]:33012 "EHLO newverein.lst.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1030814AbeCST7r (ORCPT ); Mon, 19 Mar 2018 15:59:47 -0400 Received: by newverein.lst.de (Postfix, from userid 2407) id BF8126F233; Mon, 19 Mar 2018 20:59:45 +0100 (CET) Date: Mon, 19 Mar 2018 20:59:45 +0100 From: Christoph Hellwig To: Jonas Rabenstein Cc: Scott Bauer , Jonathan Derrick , Jens Axboe , linux-block@vger.kernel.org, linux-kernel@vger.kernel.org, Christoph Hellwig Subject: Re: [PATCH v2 06/11] block: sed-opal: split generation of bytestring header and content Message-ID: <20180319195945.GH3380@lst.de> References: <0f5fe62576e70de12515e323ca5c0a45ef92832d.1521482296.git.jonas.rabenstein@studium.uni-erlangen.de> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <0f5fe62576e70de12515e323ca5c0a45ef92832d.1521482296.git.jonas.rabenstein@studium.uni-erlangen.de> User-Agent: Mutt/1.5.17 (2007-11-01) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org > +static u8 *add_bytestring_header(int *err, struct opal_dev *cmd, size_t len) > { > size_t header_len = 1; > bool is_short_atom = true; > - > - if (*err) > - return; > + char *start; Shouldn't this also return early if we have a pending error? Except for that this looks fine: Reviewed-by: Christoph Hellwig