From patchwork Fri Aug 7 15:02:18 2009 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: bugzilla-daemon@bugzilla.kernel.org X-Patchwork-Id: 30937 Return-Path: X-Original-To: patchwork-incoming@bilbo.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from ozlabs.org (ozlabs.org [203.10.76.45]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (Client CN "mx.ozlabs.org", Issuer "CA Cert Signing Authority" (verified OK)) by bilbo.ozlabs.org (Postfix) with ESMTPS id 99DA8B7093 for ; Sat, 8 Aug 2009 01:02:22 +1000 (EST) Received: by ozlabs.org (Postfix) id 8B8E1DDD0B; Sat, 8 Aug 2009 01:02:22 +1000 (EST) Delivered-To: patchwork-incoming@ozlabs.org Received: from vger.kernel.org (vger.kernel.org [209.132.176.167]) by ozlabs.org (Postfix) with ESMTP id 142F8DDD04 for ; Sat, 8 Aug 2009 01:02:21 +1000 (EST) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S932630AbZHGPCS (ORCPT ); Fri, 7 Aug 2009 11:02:18 -0400 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S932632AbZHGPCS (ORCPT ); Fri, 7 Aug 2009 11:02:18 -0400 Received: from demeter.kernel.org ([140.211.167.39]:42318 "EHLO demeter.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S932630AbZHGPCR (ORCPT ); Fri, 7 Aug 2009 11:02:17 -0400 Received: from demeter.kernel.org (localhost.localdomain [127.0.0.1]) by demeter.kernel.org (8.14.2/8.14.2) with ESMTP id n77F2IVf018454 for ; Fri, 7 Aug 2009 15:02:18 GMT Received: (from apache@localhost) by demeter.kernel.org (8.14.2/8.14.2/Submit) id n77F2I8X018452; Fri, 7 Aug 2009 15:02:18 GMT Date: Fri, 7 Aug 2009 15:02:18 GMT Message-Id: <200908071502.n77F2I8X018452@demeter.kernel.org> X-Authentication-Warning: demeter.kernel.org: apache set sender to bugzilla-daemon@bugzilla.kernel.org using -f From: bugzilla-daemon@bugzilla.kernel.org To: linux-ext4@vger.kernel.org Subject: [Bug 12793] ext4 gives wrong errno with too long extended attribute values X-Bugzilla-Reason: None X-Bugzilla-Type: newchanged X-Bugzilla-Watch-Reason: AssignedTo fs_ext4@kernel-bugs.osdl.org X-Bugzilla-Product: File System X-Bugzilla-Component: ext4 X-Bugzilla-Keywords: X-Bugzilla-Severity: normal X-Bugzilla-Who: narendramind@gmail.com X-Bugzilla-Status: NEW X-Bugzilla-Priority: P1 X-Bugzilla-Assigned-To: fs_ext4@kernel-bugs.osdl.org X-Bugzilla-Target-Milestone: --- X-Bugzilla-Changed-Fields: CC In-Reply-To: References: Auto-Submitted: auto-generated MIME-Version: 1.0 Sender: linux-ext4-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-ext4@vger.kernel.org http://bugzilla.kernel.org/show_bug.cgi?id=12793 Narendra Prasad Madanapalli changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |narendramind@gmail.com --- Comment #1 from Narendra Prasad Madanapalli 2009-08-07 15:02:16 --- The following patch fixes the issue. ====Patch ends Ran test_xattr.py on the kernel with above fix, it terminates with OSError 7. ====Patch starts iff -uNr linux-2.6.30.3-orig/fs/ext4/xattr.c linux-2.6.30.3-fix/fs/ext4/xattr.c --- linux-2.6.30.3-orig/fs/ext4/xattr.c 2009-07-25 03:17:51.000000000 +0530 +++ linux-2.6.30.3-fix/fs/ext4/xattr.c 2009-08-07 20:27:40.907412651 +0530 @@ -698,7 +698,7 @@ #define header(x) ((struct ext4_xattr_header *)(x)) if (i->value && i->value_len > sb->s_blocksize) - return -ENOSPC; + return -E2BIG; if (s->base) { ce = mb_cache_entry_get(ext4_xattr_cache, bs->bh->b_bdev, bs->bh->b_blocknr);