From patchwork Tue May 12 17:33:50 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "Denis Efremov (Oracle)" X-Patchwork-Id: 11543645 Return-Path: Received: from mail.kernel.org (pdx-korg-mail-1.web.codeaurora.org [172.30.200.123]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 2668B92A for ; Tue, 12 May 2020 17:33:57 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 0F21E20659 for ; Tue, 12 May 2020 17:33:57 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726300AbgELRd4 (ORCPT ); Tue, 12 May 2020 13:33:56 -0400 Received: from mail-lf1-f67.google.com ([209.85.167.67]:35798 "EHLO mail-lf1-f67.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726031AbgELRd4 (ORCPT ); Tue, 12 May 2020 13:33:56 -0400 Received: by mail-lf1-f67.google.com with SMTP id x73so11277240lfa.2; Tue, 12 May 2020 10:33:53 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:references:autocrypt:subject :message-id:date:user-agent:mime-version:in-reply-to :content-language:content-transfer-encoding; bh=7PJDYyaeHhNlAcvExPRKc/7NtIMxIppOaGSnAUjpGxA=; b=DPpezT44nisGGLnZ2r48DINfRf0LnKtHPEUXSNjA/xKPNkZFp5CiusCWmnVgxGEQHz 1mxLqLtWZizOayaMmvTHtxTK5pxbtRVtFO/QP77b5W8LdQKaKF91672giIDBLpzweze6 TqtFmlWcOaCYC/3xlFbZi4Ne8/gtqRXU8txWulxEqOrFGfKgbaeaq9oblEwbAQvlczoD 9PVyrzABlvVb7UD/ME0MeS2iK2M8yj09YCWUvi4ZWGCxG2KGkjVQHQqMsGSNGxxVA7Ja SsPF12w35c/R1WOEToCk9TBJWCVRSaXpntpl/cJPB6EiJzZScPPNnVyAQIhzShxEe4S5 mrzg== X-Gm-Message-State: AOAM532jaiLCkN2XlPMEOnkKV619BANNOYLt8hvvRqhG5oLJ8VTxfKH5 uxKrXIfKNPn5rdBbnyQHw8E0OPY7+i0= X-Google-Smtp-Source: ABdhPJx4fv1v087d7w7IXnltOlzwy2GrIgjHxia3EJpn0ouCyDBjgLs94ab9z0INoYjWULQO89Ngrw== X-Received: by 2002:ac2:5e24:: with SMTP id o4mr14990828lfg.37.1589304832726; Tue, 12 May 2020 10:33:52 -0700 (PDT) Received: from [192.168.1.8] ([213.87.130.150]) by smtp.gmail.com with ESMTPSA id t13sm13355480ljd.38.2020.05.12.10.33.51 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Tue, 12 May 2020 10:33:52 -0700 (PDT) From: Denis Efremov To: Jens Axboe Cc: linux-block , Linux Kernel Mailing List References: <8d8cb63b-e1ff-ddef-a6e9-8f7adb21be60@linux.com> Autocrypt: addr=efremov@linux.com; keydata= mQINBFsJUXwBEADDnzbOGE/X5ZdHqpK/kNmR7AY39b/rR+2Wm/VbQHV+jpGk8ZL07iOWnVe1 ZInSp3Ze+scB4ZK+y48z0YDvKUU3L85Nb31UASB2bgWIV+8tmW4kV8a2PosqIc4wp4/Qa2A/ Ip6q+bWurxOOjyJkfzt51p6Th4FTUsuoxINKRMjHrs/0y5oEc7Wt/1qk2ljmnSocg3fMxo8+ y6IxmXt5tYvt+FfBqx/1XwXuOSd0WOku+/jscYmBPwyrLdk/pMSnnld6a2Fp1zxWIKz+4VJm QEIlCTe5SO3h5sozpXeWS916VwwCuf8oov6706yC4MlmAqsQpBdoihQEA7zgh+pk10sCvviX FYM4gIcoMkKRex/NSqmeh3VmvQunEv6P+hNMKnIlZ2eJGQpz/ezwqNtV/przO95FSMOQxvQY 11TbyNxudW4FBx6K3fzKjw5dY2PrAUGfHbpI3wtVUNxSjcE6iaJHWUA+8R6FLnT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BfEONV5MIYH3fOb5+ r/HYPye7puSmQ2LCXy7X5IIsnAoxSrcFYq9nGfHNcXhm5x6WjYC0Kz8l4lfwWo8PIpZ8x57v gTH1PI5R4WdRQijLxLCW/AaiuoEYuOLAoW481XtZb0GRRe+Tm9z/fCbkEveyPiDK7oZahBM7 QdWEEV8mqJoOZ3xxqMlJrxKM9SDF+auB4zWGz5jGzCDAx/0qMUrVn2+v8i4oEKW6IUdV7axW Nk9a+EF5JSTbfv0JBYeSHK3WRklSYLdsMRhaCKhSbwo8Xgn/m6a92fKd3NnObvRe76iIEMSw 60iagNE6AFFzuF/GvoIHb2oDUIX4z+/D0TBWH9ADNptmuE+LZnlPUAAEzRgUFtlN5LtJP8ph Subject: [GIT PULL RESEND] Floppy cleanups for next Message-ID: <565fc2e1-a790-241f-7a98-52a4c5ff8158@linux.com> Date: Tue, 12 May 2020 20:33:50 +0300 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.7.0 MIME-Version: 1.0 In-Reply-To: <8d8cb63b-e1ff-ddef-a6e9-8f7adb21be60@linux.com> Content-Language: en-US Sender: linux-block-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-block@vger.kernel.org Rebased on for-5.8/drivers branch. The following changes since commit 92decf118f1da4c866515f80387f9cf4d48611d6: nvme: define constants for identification values (2020-05-09 16:18:36 -0600) are available in the Git repository at: https://github.com/evdenis/linux-floppy tags/floppy-for-5.8 for you to fetch changes up to 0836275df4db20daf040fff5d9a1da89c4c08a85: floppy: suppress UBSAN warning in setup_rw_floppy() (2020-05-12 19:34:57 +0300) ---------------------------------------------------------------- Floppy patches for 5.8 Cleanups: - symbolic register names for x86,sparc64,sparc32,powerpc,parisc,m68k - split of local/global variables for drive,fdc - UBSAN warning suppress in setup_rw_floppy() Changes were compile tested on arm, sparc64, powerpc, m68k. Many patches introduce no binary changes by using defines instead of magic numbers. The patches were also tested with syzkaller and simple write/read/format tests on real hardware. Signed-off-by: Denis Efremov ---------------------------------------------------------------- Denis Efremov (4): floppy: use print_hex_dump() in setup_DMA() floppy: add FD_AUTODETECT_SIZE define for struct floppy_drive_params floppy: add defines for sizes of cmd & reply buffers of floppy_raw_cmd floppy: suppress UBSAN warning in setup_rw_floppy() Willy Tarreau (27): floppy: split the base port from the register in I/O accesses floppy: add references to 82077's extra registers floppy: use symbolic register names in the m68k port floppy: use symbolic register names in the parisc port floppy: use symbolic register names in the powerpc port floppy: use symbolic register names in the sparc32 port floppy: use symbolic register names in the sparc64 port floppy: use symbolic register names in the x86 port floppy: cleanup: make twaddle() not rely on current_{fdc,drive} anymore floppy: cleanup: make reset_fdc_info() not rely on current_fdc anymore floppy: cleanup: make show_floppy() not rely on current_fdc anymore floppy: cleanup: make wait_til_ready() not rely on current_fdc anymore floppy: cleanup: make output_byte() not rely on current_fdc anymore floppy: cleanup: make result() not rely on current_fdc anymore floppy: cleanup: make need_more_output() not rely on current_fdc anymore floppy: cleanup: make perpendicular_mode() not rely on current_fdc anymore floppy: cleanup: make fdc_configure() not rely on current_fdc anymore floppy: cleanup: make fdc_specify() not rely on current_{fdc,drive} anymore floppy: cleanup: make check_wp() not rely on current_{fdc,drive} anymore floppy: cleanup: make next_valid_format() not rely on current_drive anymore floppy: cleanup: make get_fdc_version() not rely on current_fdc anymore floppy: cleanup: do not iterate on current_fdc in DMA grab/release functions floppy: cleanup: add a few comments about expectations in certain functions floppy: cleanup: do not iterate on current_fdc in do_floppy_init() floppy: make sure to reset all FDCs upon resume() floppy: cleanup: get rid of current_reqD in favor of current_drive floppy: cleanup: make set_fdc() always set current_drive and current_fd arch/alpha/include/asm/floppy.h | 4 +- arch/arm/include/asm/floppy.h | 8 +- arch/m68k/include/asm/floppy.h | 27 ++++--- arch/mips/include/asm/mach-generic/floppy.h | 8 +- arch/mips/include/asm/mach-jazz/floppy.h | 8 +- arch/parisc/include/asm/floppy.h | 19 ++--- arch/powerpc/include/asm/floppy.h | 19 ++--- arch/sparc/include/asm/floppy_32.h | 50 ++++++------ arch/sparc/include/asm/floppy_64.h | 59 +++++++------- arch/x86/include/asm/floppy.h | 19 ++--- drivers/block/floppy.c | 456 ++++++++++++++++++++++++++++++++++++++++++++++++++++++---------------------------------------------------- include/uapi/linux/fd.h | 26 +++++- include/uapi/linux/fdreg.h | 16 +++- 13 files changed, 384 insertions(+), 335 deletions(-)