Received: by 2002:a05:6a10:22f:0:0:0:0 with SMTP id 15csp515685pxk; Wed, 2 Sep 2020 07:45:42 -0700 (PDT) X-Google-Smtp-Source: ABdhPJxaud07ti4Ue3siiA3tPnuT0Q1voIja0yVgaSI7YPxwUkSN1W8sqBp+j4cXZdfcV6cfnz8e X-Received: by 2002:a50:b946:: with SMTP id m64mr451990ede.92.1599057941766; Wed, 02 Sep 2020 07:45:41 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1599057941; cv=none; d=google.com; s=arc-20160816; b=eF4aWhbz57GNfX3X2EURP7ZmKsnpLBwc1Jc8AsqtK8YI112q7E6HTEN4uxqj8Jsbcy D2IXyOpbp2rQn0r2p239F7Nox0frCf8svDX0iqiGGNVkE4IqZWO9D4wLvkKLG6ftrhE1 dXmHPmCybSGi1LtOiqJ9m7Bqb6z/R+JeIGFquiJpAF/V96wBuAMPZ5EGC/DWgxuRPBNX iAMESRAFeBbdxjthNq+Av2ZQ8Q6TbSbES3tARkCmduUwt5+wWcWrY9Sj+w448nk42cnQ waT16Jdhma4j8CwBgJpGKMLOtwkiAbPoIWw31YvUM94KnDLVuB3YbVh2iDMOnHmtrElW E0Gw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :message-id:date:subject:cc:to:from:dkim-signature; bh=qYKl1qvW+oZB7H4Eg4mySB0HdI5GaU5c+ZiBZZ0yxcM=; b=sLYnb8EpkqSStLzUh0DUST5sorsnXxlFeoN/lQkEvfK7u8qdjRhW+sfpvJtLvcj+xx ofuPrhDqvhN/IaicZ3DwQKtC5xuy7no8H2QprqJ6xMfP2iC6akTQQzbt++AOXfjsOdYP PQl0HnQ52zVbNjemQ0P1MkRA1JyeY/wuNOCKXr8/VHVnxvtmRNFcQysuftyy7rOPNG6p XcM8dyIL3B9F+6YdIkuyloybEYboLVeMWR+l2VIHtROKXeJgGsy1HpmzlJdcsvKGtK/O 3tRCCejkgZ93EeSCFfWcmyzm6QKSuwLbOBnzzj6+7IhTID0RYtYKQxYnMe4YtAaQXaKV zpsQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@infradead.org header.s=casper.20170209 header.b=AmzkX2Yu; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id f10si2635138edy.472.2020.09.02.07.45.17; Wed, 02 Sep 2020 07:45:41 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=fail header.i=@infradead.org header.s=casper.20170209 header.b=AmzkX2Yu; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726567AbgIBOl4 (ORCPT + 99 others); Wed, 2 Sep 2020 10:41:56 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:38198 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727996AbgIBONl (ORCPT ); Wed, 2 Sep 2020 10:13:41 -0400 Received: from casper.infradead.org (casper.infradead.org [IPv6:2001:8b0:10b:1236::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 23B14C06125F; Wed, 2 Sep 2020 07:12:53 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=casper.20170209; h=Content-Transfer-Encoding:MIME-Version: Message-Id:Date:Subject:Cc:To:From:Sender:Reply-To:Content-Type:Content-ID: Content-Description:In-Reply-To:References; bh=qYKl1qvW+oZB7H4Eg4mySB0HdI5GaU5c+ZiBZZ0yxcM=; b=AmzkX2Yu0z+aZrD5f6YHrfpL3Y zHD2maNr33SF3n/YbUTJgaduaR46qG9nXIDLkrpOqJ6yFd80rTZuRWCKzfUQgVrw4Cp1Z9KzIJGIl bFSXF0J06iLG5HXRHC387BuMozGmnDHaHrA5BVbr5fJcakeM5aZ2EbWffVLSVGsSyqbjh0z7o0DBZ jEkI46mBUS5lxTvW/2hsRdDse/kDy7bcxfHXSr9oZiKa5QB3DUR4lByrpZpJMt3LENV5zPQSvJOh3 A7qCWwoFc6JNBNl5ohIkPcT2Zl/QZsCcdK8EeXs5adD4mliKTwZbHg0fqsue58kZamAunNlGvSAqo l0GbvbYA==; Received: from [2001:4bb8:184:af1:6a63:7fdb:a80e:3b0b] (helo=localhost) by casper.infradead.org with esmtpsa (Exim 4.92.3 #3 (Red Hat Linux)) id 1kDTUp-0005ci-Fw; Wed, 02 Sep 2020 14:12:20 +0000 From: Christoph Hellwig To: Jens Axboe Cc: Denis Efremov , Tim Waugh , Michal Simek , Borislav Petkov , "David S. Miller" , Song Liu , "Martin K. Petersen" , Finn Thain , Michael Schmitz , linux-m68k@lists.linux-m68k.org, linux-block@vger.kernel.org, linux-kernel@vger.kernel.org, linux-ide@vger.kernel.org, linux-raid@vger.kernel.org, linux-scsi@vger.kernel.org, linux-fsdevel@vger.kernel.org Subject: rework check_disk_change() Date: Wed, 2 Sep 2020 16:11:59 +0200 Message-Id: <20200902141218.212614-1-hch@lst.de> X-Mailer: git-send-email 2.28.0 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-SRS-Rewrite: SMTP reverse-path rewritten from by casper.infradead.org. See http://www.infradead.org/rpr.html Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hi Jens, this series replaced the not very nice check_disk_change() function with a new bdev_media_changed that avoids having the ->revalidate_disk call at its end. As a result ->revalidate_disk can be removed from a lot of drivers. Diffstat: block/genhd.c | 29 ++++++++++++++++++++++++++- drivers/block/amiflop.c | 2 - drivers/block/ataflop.c | 7 +++--- drivers/block/floppy.c | 8 ++++--- drivers/block/paride/pcd.c | 2 - drivers/block/swim.c | 22 +------------------- drivers/block/swim3.c | 4 +-- drivers/block/xsysace.c | 26 +++++++++--------------- drivers/cdrom/gdrom.c | 2 - drivers/ide/ide-cd.c | 16 ++++----------- drivers/ide/ide-disk.c | 5 ---- drivers/ide/ide-floppy.c | 2 - drivers/ide/ide-gd.c | 48 +++++---------------------------------------- drivers/md/md.c | 2 - drivers/scsi/sd.c | 7 +++--- drivers/scsi/sr.c | 36 +++++++++++++-------------------- fs/block_dev.c | 31 ----------------------------- include/linux/genhd.h | 3 -- include/linux/ide.h | 2 - 19 files changed, 86 insertions(+), 168 deletions(-)