From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S932318AbcFNTJ1 (ORCPT ); Tue, 14 Jun 2016 15:09:27 -0400 Received: from zeniv.linux.org.uk ([195.92.253.2]:34958 "EHLO ZenIV.linux.org.uk" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S932087AbcFNTJ0 (ORCPT ); Tue, 14 Jun 2016 15:09:26 -0400 Date: Tue, 14 Jun 2016 20:09:23 +0100 From: Al Viro To: Jiri Kosina Cc: Wim Osterholt , linux-kernel@vger.kernel.org Subject: Re: disfunctional floppy driver in kernels 4.5, 4.6 and 4.7 Message-ID: <20160614190923.GX14480@ZenIV.linux.org.uk> References: <20160610230255.GA27770@djo.tudelft.nl> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.6.0 (2016-04-01) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Mon, Jun 13, 2016 at 02:15:15PM +0200, Jiri Kosina wrote: > Hmm, could you please test with 09954bad448 reverted? (although I don't > really have a good explanation currently how it'd be causing what you are > observing). I do, actually - ->f_mode on open(..., 3) contains neither FMODE_READ nor FMODE_WRITE. So this While at it, clean up a bit handling of !(mode & (FMODE_READ|FMODE_WRITE)) case and return EINVAL instead of succeeding as well. is working as promised in commit message.