Received: by 2002:a25:4158:0:0:0:0:0 with SMTP id o85csp2345766yba; Mon, 6 May 2019 04:35:15 -0700 (PDT) X-Google-Smtp-Source: APXvYqw7pbmAHrgZj6FwgsIcT/zLmTQQ2ty12uAH6LGNkJl876WOe+iwpLYHvsEkRgCAc3LQfOGm X-Received: by 2002:a17:902:d708:: with SMTP id w8mr31582679ply.231.1557142515154; Mon, 06 May 2019 04:35:15 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1557142515; cv=none; d=google.com; s=arc-20160816; b=EVfXfXWu9a23kF1sBGErzY8cF4WNj8CBdQ4bgTL+tYDFljYJYfUtbBQCDFg0d3ZnuE JBBT0JM1rx+GskpBJRU8EGQt/qZBkJeKPeFtHSn3F9z4F1AEszs3DUqCTanPzMsttWUc uNyzPhBMdOIYmu0WBuZWNdMQ2xB5pCgJ7p1Dpopj/ujY4q+VQgGL3aRWjHu7UGkIXfjr LwSJgYxejFJwnnTJDDD9+J7Bu8TQ9kefSid40zLfQ4E1Dsh3NdDLk5lHDvkHhkRdhwBs t8Gr6DMaw4fwKyngsLGBSjxBO/DwQBZcPKP61Sa3GSKNyrDjwsDzHgiQxnflPpdDHLvG oT0w== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:message-id:content-transfer-encoding :mime-version:references:in-reply-to:organization:date:subject:cc:to :from; bh=w3VzEosjeCrLw98zY56iZKEdyHz/hNMUEbfTYhA3+I8=; b=LL2Uo5Y5mQLykNGUNZpcI9kxNXAGe3pxuMrP2flf4ZRaFZtNp9lX6KCMBN4mTM1ZBs /pLEO3lPujNYlrwHd7NmZZtBYGYjG0lcNfoxz4aVclAjmG1q3wZLwPvGdlp0MS3Xv7EV EV7exoAOtERiAV7FBdnPxO5GdKxgjw8x42zEIbjNUDK5zSBsS15fHe2qNxrkybztSmhD oGVM/jyFHiQ3bo8I9Z6hTX7ZtxqOoEXKhtQ9Zxe8p55wisvkQEO8isVo9HKV9u8Nh7Lz Xtw6glYfkBipu+fP5V2nwJqSGdTJwWJyIns6S73iS0xStOYDIGmFmPRSczlJFz/WenXf rDBQ== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-ext4-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-ext4-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=ibm.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id e22si14750982pgi.66.2019.05.06.04.34.59; Mon, 06 May 2019 04:35:15 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-ext4-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-ext4-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-ext4-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=ibm.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726034AbfEFLe6 (ORCPT + 99 others); Mon, 6 May 2019 07:34:58 -0400 Received: from mx0b-001b2d01.pphosted.com ([148.163.158.5]:51568 "EHLO mx0a-001b2d01.pphosted.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1725852AbfEFLe6 (ORCPT ); Mon, 6 May 2019 07:34:58 -0400 Received: from pps.filterd (m0098419.ppops.net [127.0.0.1]) by mx0b-001b2d01.pphosted.com (8.16.0.27/8.16.0.27) with SMTP id x46BYiTU126482 for ; Mon, 6 May 2019 07:34:56 -0400 Received: from e06smtp01.uk.ibm.com (e06smtp01.uk.ibm.com [195.75.94.97]) by mx0b-001b2d01.pphosted.com with ESMTP id 2sam0489wu-1 (version=TLSv1.2 cipher=AES256-GCM-SHA384 bits=256 verify=NOT) for ; Mon, 06 May 2019 07:34:55 -0400 Received: from localhost by e06smtp01.uk.ibm.com with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted for from ; Mon, 6 May 2019 12:33:36 +0100 Received: from b06cxnps4076.portsmouth.uk.ibm.com (9.149.109.198) by e06smtp01.uk.ibm.com (192.168.101.131) with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted; (version=TLSv1/SSLv3 cipher=AES256-GCM-SHA384 bits=256/256) Mon, 6 May 2019 12:33:33 +0100 Received: from d06av26.portsmouth.uk.ibm.com (d06av26.portsmouth.uk.ibm.com [9.149.105.62]) by b06cxnps4076.portsmouth.uk.ibm.com (8.14.9/8.14.9/NCO v10.0) with ESMTP id x46BXWb446465208 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Mon, 6 May 2019 11:33:32 GMT Received: from d06av26.portsmouth.uk.ibm.com (unknown [127.0.0.1]) by IMSVA (Postfix) with ESMTP id 8CA04AE056; Mon, 6 May 2019 11:33:32 +0000 (GMT) Received: from d06av26.portsmouth.uk.ibm.com (unknown [127.0.0.1]) by IMSVA (Postfix) with ESMTP id 20D5FAE04D; Mon, 6 May 2019 11:33:31 +0000 (GMT) Received: from localhost.localdomain (unknown [9.85.70.42]) by d06av26.portsmouth.uk.ibm.com (Postfix) with ESMTP; Mon, 6 May 2019 11:33:30 +0000 (GMT) From: Chandan Rajendra To: Eric Biggers Cc: linux-fscrypt@vger.kernel.org, linux-ext4@vger.kernel.org, linux-f2fs-devel@lists.sourceforge.net, linux-mtd@lists.infradead.org, linux-fsdevel@vger.kernel.org Subject: Re: [PATCH 04/13] fscrypt: clean up some BUG_ON()s in block encryption/decryption Date: Mon, 06 May 2019 13:54:45 +0530 Organization: IBM In-Reply-To: <20190501224515.43059-5-ebiggers@kernel.org> References: <20190501224515.43059-1-ebiggers@kernel.org> <20190501224515.43059-5-ebiggers@kernel.org> MIME-Version: 1.0 Content-Transfer-Encoding: 7Bit Content-Type: text/plain; charset="us-ascii" X-TM-AS-GCONF: 00 x-cbid: 19050611-4275-0000-0000-00000331DF52 X-IBM-AV-DETECTION: SAVI=unused REMOTE=unused XFE=unused x-cbparentid: 19050611-4276-0000-0000-000038414613 Message-Id: <4366146.XrkeSAOiMl@dhcp-9-109-212-164> X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10434:,, definitions=2019-05-06_07:,, signatures=0 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 priorityscore=1501 malwarescore=0 suspectscore=1 phishscore=0 bulkscore=0 spamscore=0 clxscore=1015 lowpriorityscore=0 mlxscore=0 impostorscore=0 mlxlogscore=581 adultscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.0.1-1810050000 definitions=main-1905060102 Sender: linux-ext4-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-ext4@vger.kernel.org On Thursday, May 2, 2019 4:15:06 AM IST Eric Biggers wrote: > From: Eric Biggers > > Replace some BUG_ON()s with WARN_ON_ONCE() and returning an error code, > and move the check for len divisible by FS_CRYPTO_BLOCK_SIZE into > fscrypt_crypt_block() so that it's done for both encryption and > decryption, not just encryption. Looks good to me, Reviewed-by: Chandan Rajendra -- chandan