Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S262883AbTFDFkM (ORCPT ); Wed, 4 Jun 2003 01:40:12 -0400 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S262884AbTFDFkL (ORCPT ); Wed, 4 Jun 2003 01:40:11 -0400 Received: from carisma.slowglass.com ([195.224.96.167]:26629 "EHLO phoenix.infradead.org") by vger.kernel.org with ESMTP id S262883AbTFDFkL (ORCPT ); Wed, 4 Jun 2003 01:40:11 -0400 Date: Wed, 4 Jun 2003 06:53:36 +0100 From: Christoph Hellwig To: "P. Benie" Cc: Linus Torvalds , Kernel Mailing List Subject: Re: [PATCH] [2.5] Non-blocking write can block Message-ID: <20030604065336.A7755@infradead.org> Mail-Followup-To: Christoph Hellwig , "P. Benie" , Linus Torvalds , Kernel Mailing List References: Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.2.5.1i In-Reply-To: ; from pjb1008@eng.cam.ac.uk on Wed, Jun 04, 2003 at 01:58:02AM +0100 Sender: linux-kernel-owner@vger.kernel.org X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 584 Lines: 16 On Wed, Jun 04, 2003 at 01:58:02AM +0100, P. Benie wrote: > - if (down_interruptible(&tty->atomic_write)) { > - return -ERESTARTSYS; > + if (file->f_flags & O_NONBLOCK) { > + if (down_trylock(&tty->atomic_write)) > + return -EAGAIN; > + } > + else { The else should be on the same line as the closing brace, else the patch looks fine. - To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/