From patchwork Sat Sep 8 14:28:07 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Arnd Bergmann X-Patchwork-Id: 146233 Delivered-To: patch@linaro.org Received: by 2002:a2e:1648:0:0:0:0:0 with SMTP id 8-v6csp625179ljw; Sat, 8 Sep 2018 07:28:48 -0700 (PDT) X-Google-Smtp-Source: ANB0VdbHVyuRwG/6Yf+9PY3vZMBu5kvGzZbI+YMCU5dBoWwWUy8ucqtzEmmj/QmfhRhwx+1WG1P7 X-Received: by 2002:a17:902:561:: with SMTP id 88-v6mr13013387plf.320.1536416927992; Sat, 08 Sep 2018 07:28:47 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1536416927; cv=none; d=google.com; s=arc-20160816; b=XMEfedcw6hgGMTrW6DKd2xEG1EiHWbNR4qaeUoXNXhjoignYy24qjqmZTr4SHK0udi Mya3dPcyZX6fUsRJudP6kyT1vZr3QgLP16ifksERkgBHDdKrjsa4zF3vcu+wgxfAYV9S IAda/5PIgHJ2jYAWTqi/LWKMpNQln3rJewz5vodS8ld4DSmQeguif4557MExssPYQEJJ XiYCkQiDlJ2nGI6Q5UjxkaDtM7ayY5FYT2+K6nXU12hlajMO/1/G7uetKBBDimPMgEg3 atNGrTT3KYtOQY/urZtzKdDekQhFkorYQieqK7zpfS7p4bvGwN397i7juvtqKa6E03mA eefQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:message-id:date:subject:cc:to:from; bh=riaWTGWUiP2xge9OR445XzT2MU24UqjqNk8GbjwT6+Y=; b=catUIdlt7NUftWdELrB+K2kG71GSCTZNN75E6op6uan/GFgVLT2A1Jz0Kj9Y8mArek LVKHAa6sSoeKdckybIWZENfCy5oU4D3L5lLJJUABUgUoUWW/KtA84gYIJB2xm45NePcK Xd7N7ha24sN+TsTLz29vrN3sT6N0Pqfrp1GoXDcoQrg/ttvjtCxw3YUT14Aof3SKg8x1 FEhoI3Z8h+OFWjYdLUPBT8Wb0uijOUyFrfLAC8K3jcZf4ACgAFiuvgM/A96GHyeMeqZw 9S37kNaBsy6dEpOF1KKQ7LJgxepoKyjLnp0vCXeBiEnKTQXgEKJO/bNo0CZtm3xlv8pA iaLw== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id s195-v6si11969075pgs.492.2018.09.08.07.28.47; Sat, 08 Sep 2018 07:28:47 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727008AbeIHTOk (ORCPT + 32 others); Sat, 8 Sep 2018 15:14:40 -0400 Received: from mout.kundenserver.de ([212.227.126.130]:60997 "EHLO mout.kundenserver.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726351AbeIHTOk (ORCPT ); Sat, 8 Sep 2018 15:14:40 -0400 Received: from wuerfel.lan ([109.193.40.16]) by mrelayeu.kundenserver.de (mreue011 [212.227.15.129]) with ESMTPA (Nemesis) id 1MtO4E-1fja7C2jHC-00us4C; Sat, 08 Sep 2018 16:28:40 +0200 From: Arnd Bergmann To: viro@zeniv.linux.org.uk Cc: Arnd Bergmann , linux-fsdevel@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH 01/11] compat_ioctl: remove keyboard ioctl translation Date: Sat, 8 Sep 2018 16:28:07 +0200 Message-Id: <20180908142837.2819693-1-arnd@arndb.de> X-Mailer: git-send-email 2.18.0 X-Provags-ID: V03:K1:Gz8Xz6xl87kUTIzpUST9fXtlPaHTobfeRYO3+pf3eMsd4Ck/d85 5ItkPxs+5a6/WChTlqUCiSCyfh8vMMaaq+vt6J427MFBvlfz0IcKjuuhr+YBq9csEJaf3t/ Lardw6pIIsDI9Qdb5nAariLPcws01/eOgBt/zzPwatnj+3m+UI+f4NLmAuV8P8t77MbGBiM 6ROJgVhNbg/T5UMmWoUfQ== X-UI-Out-Filterresults: notjunk:1; V01:K0:27Pqvg3AFhU=:uNkLBf8C+9w11YLvPCfrPf 15h2unUxaZPoAptUKCID34yK2FtnaUcaJrIQ6Tm5mmmxvXAN26Y8rYJTkc8bQhZeB3kHPMxGx +zcZk/Ke02N+StrWkraTHvoPFCHqSCgsEadsVGl0QAP6BJ7EeD7wv5cet0AYnVfoFM4NxjGC9 M2LktmpLkjKpnhNzAJLO4fIEeKsmzWYwOBVtWanqZH1qGhmPR2IxLsA0c7ANcLmEEc3t9GOTl A6dKJvpm1B3KWp6UukS5dVkq+Qogeg1BMuPAN+FNnQyFu2GjRkrQEvgGc7HGMbH5djP0nKO2x 9OREChJ84Dki6n78f9DLxuJ5qXJorRgnwfoTDSWdrHWdj2daFbs+kucIwG+B6oM5svcSB/2bq R4Jpk8qnnkyVzmEwoaJGC2mk+jjdycNs19+L4cGG204VmmiR0igUkGoRNbebrFTC9Zi1SFwKQ IjDS0rVubh1GkN3QctzogqsEXjT4+TSCbBUPY2w9ele9Jt8JHEY1mb1j0cZdGVrRb0yJE4tKL NeVsE2NB/ufXW4Z+fhPK5xSXAT+sh/bVGAhTy4skxaAi7xsCOwnGJogD7lLmHwvtcg6pkbbts ApNKoo6C1QRfzWg2FktyXpaB7BiqmaZ/lxrPo2lUgByhDqdCE5HAClW7nFAy5QKRPuHTSVzsY mQFckiMUPW+JIEDLpNlItot0oEnFAR34+V7WoB4ih+kOgEmhoI78deNqhshI/FhrK0oI= Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org The KD* family of ioctls is implemented in two drivers: drivers/tty/vt and drivers/s390/char/tty3270.c. Both of them have compat handlers for all their ioctl commands, so translation in fs/compat_ioctl.c is never used. Commit fb07a5f857ac ("compat_ioctl: remove all VT ioctl handling") removed the compat handling for all the other VT ioctls back in 2009, but it seems I missed the keyboard ones back then. Signed-off-by: Arnd Bergmann --- fs/compat_ioctl.c | 26 -------------------------- 1 file changed, 26 deletions(-) -- 2.18.0 diff --git a/fs/compat_ioctl.c b/fs/compat_ioctl.c index 9237076bdcf5..4c2f83a386a2 100644 --- a/fs/compat_ioctl.c +++ b/fs/compat_ioctl.c @@ -546,23 +546,6 @@ COMPATIBLE_IOCTL(FIGETBSZ) COMPATIBLE_IOCTL(FIFREEZE) COMPATIBLE_IOCTL(FITHAW) COMPATIBLE_IOCTL(FITRIM) -COMPATIBLE_IOCTL(KDGETKEYCODE) -COMPATIBLE_IOCTL(KDSETKEYCODE) -COMPATIBLE_IOCTL(KDGKBTYPE) -COMPATIBLE_IOCTL(KDGETMODE) -COMPATIBLE_IOCTL(KDGKBMODE) -COMPATIBLE_IOCTL(KDGKBMETA) -COMPATIBLE_IOCTL(KDGKBENT) -COMPATIBLE_IOCTL(KDSKBENT) -COMPATIBLE_IOCTL(KDGKBSENT) -COMPATIBLE_IOCTL(KDSKBSENT) -COMPATIBLE_IOCTL(KDGKBDIACR) -COMPATIBLE_IOCTL(KDSKBDIACR) -COMPATIBLE_IOCTL(KDGKBDIACRUC) -COMPATIBLE_IOCTL(KDSKBDIACRUC) -COMPATIBLE_IOCTL(KDKBDREP) -COMPATIBLE_IOCTL(KDGKBLED) -COMPATIBLE_IOCTL(KDGETLED) #ifdef CONFIG_BLOCK /* Big S */ COMPATIBLE_IOCTL(SCSI_IOCTL_GET_IDLUN) @@ -974,15 +957,6 @@ static long do_ioctl_trans(unsigned int cmd, case HOT_ADD_DISK: case SET_DISK_FAULTY: case SET_BITMAP_FILE: - /* Big K */ - case KDSIGACCEPT: - case KIOCSOUND: - case KDMKTONE: - case KDSETMODE: - case KDSKBMODE: - case KDSKBMETA: - case KDSKBLED: - case KDSETLED: return vfs_ioctl(file, cmd, arg); } From patchwork Sat Sep 8 14:28:08 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Arnd Bergmann X-Patchwork-Id: 146234 Delivered-To: patch@linaro.org Received: by 2002:a2e:1648:0:0:0:0:0 with SMTP id 8-v6csp625274ljw; Sat, 8 Sep 2018 07:28:57 -0700 (PDT) X-Google-Smtp-Source: ANB0VdYhyZ4qhgvGfY736H39fyfrOZitiHSKDF+4s5Zb7Np/hnAG84dpCXOrrmNxfOP5rRgn992w X-Received: by 2002:a17:902:561:: with SMTP id 88-v6mr13013886plf.320.1536416936933; Sat, 08 Sep 2018 07:28:56 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1536416936; cv=none; d=google.com; s=arc-20160816; b=A1kRIpMTosG5UCpywG2lNbyoiV+nnDnNKbKR83D8hcHzR7tGR7vpAK/eyezrtU7QB5 O/F05HNFNwTEU1D/b8jgwwLBDR8fICoKA1dXl6W/nfwzlpAcubwriD7i239yiJ/fdmOQ tQ3rOo0VjnUJ2uLxu7BRaMXcdyW8WUPUwFLA9Vc76iD7BPCT9xkoStMfm93WkJAry6Ja c/8X063NCDdM2nG1BdVLqS/mOUEQXEF8cqgKgEvK4A54XSxV9yEnFk1P+DNyPWF+a2Cu Pf5AjfzOlrL2DLTJGG3U4l7wMkuCCzDC/hpigTuUJ6ZMgrbP7Q4ImkNjEhCyGKtutEBR DIgA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:references:in-reply-to:message-id:date :subject:cc:to:from; bh=Kc7O5tzKDVMBBt4hIdZMdbQuAzb3GcBztQzOWgm+buY=; b=WrLkPRuBSkH1N1S+zh157Y4IkfqaDFPuyrhhz9K0Y8xTLt6aNEoBuliKEZa5UZEXWZ OX5EzBOeveR1PV/i2acVm8QUNztKhjuFnsg6yeS1aXacobP8huQs3xxtaxDwl9xFMqUF 2mQfbFihqyX5O4rAqyhuWDjq6lC3xBMcKBdov+P1Z8s0MhYT8TkDUjBQGaClBpKIHGgK D1SKm2IsgAYBzFrx5a+AYW4mYDKItdpMWSl/g6xLn/h+1cEcp1Iw+ace0D9IIWAzmUTm 0iMPcjEPt6ag9p0D9NewncR3+mQR8nQv87rCrmvwUkIdk2suZyzwlyiHEQYO+fGEdPP9 c5Lw== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id u6-v6si12088851pfu.143.2018.09.08.07.28.56; Sat, 08 Sep 2018 07:28:56 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727126AbeIHTOv (ORCPT + 32 others); Sat, 8 Sep 2018 15:14:51 -0400 Received: from mout.kundenserver.de ([212.227.126.133]:36077 "EHLO mout.kundenserver.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726351AbeIHTOv (ORCPT ); Sat, 8 Sep 2018 15:14:51 -0400 Received: from wuerfel.lan ([109.193.40.16]) by mrelayeu.kundenserver.de (mreue011 [212.227.15.129]) with ESMTPA (Nemesis) id 1MQusJ-1gC2Fg0z9r-00O0Hd; Sat, 08 Sep 2018 16:28:51 +0200 From: Arnd Bergmann To: viro@zeniv.linux.org.uk Cc: Arnd Bergmann , linux-fsdevel@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH 02/11] compat_ioctl: remove HIDIO translation Date: Sat, 8 Sep 2018 16:28:08 +0200 Message-Id: <20180908142837.2819693-2-arnd@arndb.de> X-Mailer: git-send-email 2.18.0 In-Reply-To: <20180908142837.2819693-1-arnd@arndb.de> References: <20180908142837.2819693-1-arnd@arndb.de> X-Provags-ID: V03:K1:1I7Gcze/afAgmffd/3BD2ZlxrLv3YnhRyEl67SMr2RW79rV+nw6 9xDXgu89vBFFY4343FDY/bphWCuqeVrHTjzmx5Qzr4mMnc3y2KPsd4mq9wtPFzoOiqt6m9V tuZC3KfeiFYYBpUqReoiB0+vMrIbeHwbyGsCa7JxOdlhm50ruymRLiiEQ2DCc2Et3ZaTkC9 1SJtdld4JYRTkl/VjXeBQ== X-UI-Out-Filterresults: notjunk:1; V01:K0:IjpLeV6cdrY=:xBVd5L/OjCLh7ic+RKjJ/C 4EnnCtZH6/a/caSeTKpIisQaejYJt1dN1yrVlhXIeWSJcLUn8NwW3oarsFFzS2qMFgITKT2Vi ECD3fya2lOHkvFxrl7iu7wmAm21alDrfBvb70fxEDtRPldlDYtmIinDy+UCAVsJGtOycONMqe kdG7ktr7tZk4uHXs/aYyogI1dWVZABadxX3s7TcHmruSuLRBoV5ovBvaBV6WPToooMrmvHe7s QhQph8iWfpTNPntV9X3Vs7mNLBzLEbn57qZGx17t6YajDkxd0UUCleFWmq3P8ojGSiE846+qe XXBADtVORCdbAdxffzyPFunXEmnvilnXPuV3DsFxNAOcE2pLYX/6K7bdFBO44OWDw5sUEwo9N gfgAzB8dp5do2EywwW+2pCsqaWr3qEHegZot0cEsTbrKUWRCfpKFujCQ9j4xura8hwujKKlVC yiHxAFRkiXGA1E+zv0iiWshs3fVlbrKmnzUTKOc4BpamyocMdQGW+ScLU860HHxlFtmqHizTn Vr8ddQvaOSK5AZZEwD//5pvhpFIM1vMAKqY+BL+4eYrrf9OKwd++eRhuX3aTrv1k/bC9nDJlS 9W9NjDPpW4hc9Rt8LLcJWE/xMNLxZYRq+R3qw+4P//PU+6O5l1Q/w4RuBidc0ZA4LGcCIsDhy F6S76PTZzexI8tPc9Hq8X0pzd5+hTZ/ibPCrHw0KKQU2pGjq//10DQz2Tov+kChoGYFw= Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org The two drivers implementing these both gained proper compat_ioctl() handlers a long time ago with commits bb6c8d8fa9b5 ("HID: hiddev: Add 32bit ioctl compatibilty") and ae5e49c79c05 ("HID: hidraw: add compatibility ioctl() for 32-bit applications."), so the lists in fs/compat_ioctl.c are no longer used. It appears that the lists were also incomplete, so the translation didn't actually work correctly when it was still in use. Remove them as cleanup. Signed-off-by: Arnd Bergmann --- fs/compat_ioctl.c | 17 ----------------- 1 file changed, 17 deletions(-) -- 2.18.0 diff --git a/fs/compat_ioctl.c b/fs/compat_ioctl.c index 4c2f83a386a2..c2c73b802fb3 100644 --- a/fs/compat_ioctl.c +++ b/fs/compat_ioctl.c @@ -853,23 +853,6 @@ COMPATIBLE_IOCTL(PCIIOC_CONTROLLER) COMPATIBLE_IOCTL(PCIIOC_MMAP_IS_IO) COMPATIBLE_IOCTL(PCIIOC_MMAP_IS_MEM) COMPATIBLE_IOCTL(PCIIOC_WRITE_COMBINE) -/* hiddev */ -COMPATIBLE_IOCTL(HIDIOCGVERSION) -COMPATIBLE_IOCTL(HIDIOCAPPLICATION) -COMPATIBLE_IOCTL(HIDIOCGDEVINFO) -COMPATIBLE_IOCTL(HIDIOCGSTRING) -COMPATIBLE_IOCTL(HIDIOCINITREPORT) -COMPATIBLE_IOCTL(HIDIOCGREPORT) -COMPATIBLE_IOCTL(HIDIOCSREPORT) -COMPATIBLE_IOCTL(HIDIOCGREPORTINFO) -COMPATIBLE_IOCTL(HIDIOCGFIELDINFO) -COMPATIBLE_IOCTL(HIDIOCGUSAGE) -COMPATIBLE_IOCTL(HIDIOCSUSAGE) -COMPATIBLE_IOCTL(HIDIOCGUCODE) -COMPATIBLE_IOCTL(HIDIOCGFLAG) -COMPATIBLE_IOCTL(HIDIOCSFLAG) -COMPATIBLE_IOCTL(HIDIOCGCOLLECTIONINDEX) -COMPATIBLE_IOCTL(HIDIOCGCOLLECTIONINFO) /* joystick */ COMPATIBLE_IOCTL(JSIOCGVERSION) COMPATIBLE_IOCTL(JSIOCGAXES) From patchwork Sat Sep 8 14:28:10 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Arnd Bergmann X-Patchwork-Id: 146236 Delivered-To: patch@linaro.org Received: by 2002:a2e:1648:0:0:0:0:0 with SMTP id 8-v6csp626553ljw; Sat, 8 Sep 2018 07:30:35 -0700 (PDT) X-Google-Smtp-Source: ANB0Vdb8wjLH12mzQECTk7V22Te5ub+gLZAXbUmXVo8qpf+ZOCnE81vhCXfaeVXf346X4a2Cl5Dp X-Received: by 2002:a17:902:42a3:: with SMTP id h32-v6mr13254750pld.105.1536417035210; Sat, 08 Sep 2018 07:30:35 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1536417035; cv=none; d=google.com; s=arc-20160816; b=uVvW7GFcZAOiJhzD0fXS/1IlJuG+gtuu6/8BLd2uNNJ3npAS2i0WMGFhlnznIHfEXL GTi5IzeoSQ2O0OroPTHeBJWm+zf2Oa070YwfXlc1rn0JBGdpajcxett4ZUYkcOchAPFo dHQeGB8v1sL4KkFbUsNJB8UWisqn/d3f1PKJ2lmvDbbeFJtZRwhNAgZjCp9DfhphRwjg RBKlvVEXsurjU1gZKGxBBZtB2sVjUlajxVLu3iN02V+ls606IHz/Ey48uJbZFexQ/8dE UALXOxBRvdNEJL8SAFBgDB4C8Tsc/FRpJLh0VH53CBq/9SFQoZ75Jth9v6U9AnsTkSMj xMOg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:references:in-reply-to:message-id:date :subject:cc:to:from; bh=GaZGBhNRz9QJnhREeegHwBQnLHVk1HqIhxmEpKXdjck=; b=QRl1EUqx4fKHP+GoVcLX36EOHlhqn1/jW8dWr+bkT17naEWWchriSJugYTCNP+2CwL Ay2CEljOCKqNivG0Vf2auIlDsV3ZjKV4+mVSe6adwz0koL93jiXVx0z9cSNuo0pLWnhv IRVbgm+5EkcBKimvae+B1fb6do4VVIuBarit2yoaxS+Mn3bjb+OXmqUhlIf3rURun/wm ilJrHWFGE7aM3E6hUjuo0bY4xx81FEESFx5NEL7VtuT+NXk972IVNdpnkMIh/ZUqI5jy K21mxDVnqLtrO6JeH37bGantlwGyW5oLxImS8o3I6W0ESKgCPKbyYijmv27pedLgDCMH YePg== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id f16-v6si11905896pff.13.2018.09.08.07.30.34; Sat, 08 Sep 2018 07:30:35 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727413AbeIHTQc (ORCPT + 32 others); Sat, 8 Sep 2018 15:16:32 -0400 Received: from mout.kundenserver.de ([212.227.126.187]:46373 "EHLO mout.kundenserver.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726351AbeIHTQc (ORCPT ); Sat, 8 Sep 2018 15:16:32 -0400 Received: from wuerfel.lan ([109.193.40.16]) by mrelayeu.kundenserver.de (mreue011 [212.227.15.129]) with ESMTPA (Nemesis) id 1MFsER-1g5WvQ3FwF-00HMTN; Sat, 08 Sep 2018 16:30:23 +0200 From: Arnd Bergmann To: viro@zeniv.linux.org.uk Cc: Arnd Bergmann , Karsten Keil , Paul Bolle , netdev@vger.kernel.org, linux-kernel@vger.kernel.org, gigaset307x-common@lists.sourceforge.net, linux-fsdevel@vger.kernel.org Subject: [PATCH 04/11] compat_ioctl: remove isdn ioctl translation Date: Sat, 8 Sep 2018 16:28:10 +0200 Message-Id: <20180908142837.2819693-4-arnd@arndb.de> X-Mailer: git-send-email 2.18.0 In-Reply-To: <20180908142837.2819693-1-arnd@arndb.de> References: <20180908142837.2819693-1-arnd@arndb.de> X-Provags-ID: V03:K1:WgQp1kucjzT9wpU82gmyNa2NWeV+CUQUCZhKJKPf+jQrikhscCh oZ29mZnpA1q27MxKVC+RNzANQPqkL8aaFxXruUYtKZZIOK4WYLCJfpb9nwCLOrgrmyELvzQ pNw5Xncgxtu9+xUX2radRs5iruAzaP/9LjiFGHaV95QpvFsD9OLmU0L+s7QCat7aj+plFNj jSEeOB9uYBxMcrcqiRUig== X-UI-Out-Filterresults: notjunk:1; V01:K0:v6ytYpd0Njg=:PCa9TBvgLaTRpp//15zQuX ZDmAtx/uUtW7TaGRasUMQwQd37lmsWVzBf2lhZOQsWBh2aQeUeTnZCWHRzBKYZlnGTjD522BN 5MUGKDPsSI/uw2qJwm2UiswVZeViNXOTv/xVpCNPwm7tQmIcqRXmbl35ET7oBUHYQNUEWNLOf HCx2gaZsFrKnToX/rkpNJ2IyprghqiIWTmG+v65JrCK0ELzwDx2X2MaZJG/l/kyA6R96N+b6K hGjGY0CAt2QbCY87skNcgA752wQFVgtntsktgc9gP6rWkmLNTePzu4uJjeJ4crkP/7lh5u6bc Atj4arnpsx6VvT1lFqOcILC5p9hK4ejKmL01FgPgbYa2Ap7xTe2ZGHccVb9GKv8Tk1I0FHcsw 9qNvH8OJoMVnMkuCy0J23Ks7pGXgVtDG1Z/+z1/J2ZpE/gvJPml3n2ydb5g2hGu8d3aj0NiIR WX0zbg733ACCA/JnWN2qVBiI14KeZQ/xy1UDKzf8fE5/81fIokVdrq49yDVIObY6K+a+dUKos 4m+9xEGxtkA6oCD0N2pVBvNkjW/4JPq8QaQAhaJ/PXqN6xkbFBp404PoPTwtuG0YkTmOz1fo2 EAoz0zUSK4iYN78V/c1ambpeAc5wQJKOQ6Z0wOeeISEH8GtQy1NR5fJ4TiSL4Nu/86oUrjaYm Eg6eMZLDjiWxVgfHq/pTswVQ4PpMgegoviJNbTl1c3C0GEZT6PKir9hYWSWeTpaH2Fb4= Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Neither the old isdn4linux interface nor the newer mISDN stack ever had working 32-bit compat mode as far as I can tell. However, the CAPI stack and the Gigaset ISDN driver (implemented on top of either CAPI or i4l) have some ioctl commands that are correctly listed in fs/compat_ioctl.c. We can trivially move all of those into the two corresponding files that implement the native handlers by adding a compat_ioctl redirect to that. I did notice that treating CAPI_MANUFACTURER_CMD() as compatible is broken, so I'm also adding a handler for that, realizing that in all likelyhood, nobody is ever going to call it. Signed-off-by: Arnd Bergmann --- drivers/isdn/capi/capi.c | 31 +++++++++++++++++++++++++++++++ drivers/isdn/gigaset/interface.c | 10 ++++++++++ fs/compat_ioctl.c | 22 ---------------------- 3 files changed, 41 insertions(+), 22 deletions(-) -- 2.18.0 diff --git a/drivers/isdn/capi/capi.c b/drivers/isdn/capi/capi.c index ef5560b848ab..4851dc3941eb 100644 --- a/drivers/isdn/capi/capi.c +++ b/drivers/isdn/capi/capi.c @@ -942,6 +942,34 @@ capi_unlocked_ioctl(struct file *file, unsigned int cmd, unsigned long arg) return ret; } +#ifdef CONFIG_COMPAT +static long +capi_compat_ioctl(struct file *file, unsigned int cmd, unsigned long arg) +{ + int ret; + + if (cmd == CAPI_MANUFACTURER_CMD) { + struct { + unsigned long cmd; + compat_uptr_t data; + } mcmd32; + + if (!capable(CAP_SYS_ADMIN)) + return -EPERM; + if (copy_from_user(&mcmd32, compat_ptr(arg), sizeof(mcmd32))) + return -EFAULT; + + mutex_lock(&capi_mutex); + ret = capi20_manufacturer(mcmd32.cmd, compat_ptr(mcmd32.data)); + mutex_unlock(&capi_mutex); + + return ret; + } + + return capi_unlocked_ioctl(file, cmd, (unsigned long)compat_ptr(arg)); +} +#endif + static int capi_open(struct inode *inode, struct file *file) { struct capidev *cdev; @@ -988,6 +1016,9 @@ static const struct file_operations capi_fops = .write = capi_write, .poll = capi_poll, .unlocked_ioctl = capi_unlocked_ioctl, +#ifdef CONFIG_COMPAT + .compat_ioctl = capi_compat_ioctl, +#endif .open = capi_open, .release = capi_release, }; diff --git a/drivers/isdn/gigaset/interface.c b/drivers/isdn/gigaset/interface.c index 600c79b030cd..faae8ae54802 100644 --- a/drivers/isdn/gigaset/interface.c +++ b/drivers/isdn/gigaset/interface.c @@ -233,6 +233,13 @@ static int if_ioctl(struct tty_struct *tty, return retval; } +#ifdef CONFIG_COMPAT +static long if_compat_ioctl(struct tty_struct *tty, unsigned int cmd, unsigned long arg) +{ + return if_ioctl(tty, cmd, (unsigned long)compat_ptr(arg)); +} +#endif + static int if_tiocmget(struct tty_struct *tty) { struct cardstate *cs = tty->driver_data; @@ -472,6 +479,9 @@ static const struct tty_operations if_ops = { .open = if_open, .close = if_close, .ioctl = if_ioctl, +#ifdef CONFIG_COMPAT + .compat_ioctl = if_compat_ioctl, +#endif .write = if_write, .write_room = if_write_room, .chars_in_buffer = if_chars_in_buffer, diff --git a/fs/compat_ioctl.c b/fs/compat_ioctl.c index 875516658c39..7d8c5722fd0a 100644 --- a/fs/compat_ioctl.c +++ b/fs/compat_ioctl.c @@ -61,9 +61,6 @@ #include #include -#include -#include - #ifdef CONFIG_BLOCK #include #include @@ -670,25 +667,6 @@ COMPATIBLE_IOCTL(HIDPCONNADD) COMPATIBLE_IOCTL(HIDPCONNDEL) COMPATIBLE_IOCTL(HIDPGETCONNLIST) COMPATIBLE_IOCTL(HIDPGETCONNINFO) -/* CAPI */ -COMPATIBLE_IOCTL(CAPI_REGISTER) -COMPATIBLE_IOCTL(CAPI_GET_MANUFACTURER) -COMPATIBLE_IOCTL(CAPI_GET_VERSION) -COMPATIBLE_IOCTL(CAPI_GET_SERIAL) -COMPATIBLE_IOCTL(CAPI_GET_PROFILE) -COMPATIBLE_IOCTL(CAPI_MANUFACTURER_CMD) -COMPATIBLE_IOCTL(CAPI_GET_ERRCODE) -COMPATIBLE_IOCTL(CAPI_INSTALLED) -COMPATIBLE_IOCTL(CAPI_GET_FLAGS) -COMPATIBLE_IOCTL(CAPI_SET_FLAGS) -COMPATIBLE_IOCTL(CAPI_CLR_FLAGS) -COMPATIBLE_IOCTL(CAPI_NCCI_OPENCOUNT) -COMPATIBLE_IOCTL(CAPI_NCCI_GETUNIT) -/* Siemens Gigaset */ -COMPATIBLE_IOCTL(GIGASET_REDIR) -COMPATIBLE_IOCTL(GIGASET_CONFIG) -COMPATIBLE_IOCTL(GIGASET_BRKCHARS) -COMPATIBLE_IOCTL(GIGASET_VERSION) /* Misc. */ COMPATIBLE_IOCTL(0x41545900) /* ATYIO_CLKR */ COMPATIBLE_IOCTL(0x41545901) /* ATYIO_CLKW */ From patchwork Sat Sep 8 14:28:11 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Arnd Bergmann X-Patchwork-Id: 146237 Delivered-To: patch@linaro.org Received: by 2002:a2e:1648:0:0:0:0:0 with SMTP id 8-v6csp626695ljw; Sat, 8 Sep 2018 07:30:44 -0700 (PDT) X-Google-Smtp-Source: ANB0VdbZPqntFgv8xltcadgwsoV68nvyGJ/OtDOsYaJXKxATgUyfxPtzzkrphgGkZdpW+BtYD4GH X-Received: by 2002:a17:902:bf43:: with SMTP id u3-v6mr13108147pls.88.1536417044310; Sat, 08 Sep 2018 07:30:44 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1536417044; cv=none; d=google.com; s=arc-20160816; b=e3J8I2dAvEv1ySRst58l2ttogrrgt2SejX04nW2hB70H/w/IhCvsp+6353v+M/nx5r ww7vnR3iHH7iUPokphJgHpnRGHHUUXJI/VSt4tL9sYjZRHlGZEoTLt0JJzyP3gu2NdBu CNFP6sOikj7cHtemI26AFTn74yXXCSwfEFNfqL9lq+WzQWyKiiCYFg6ggcjDIFMk80Z8 dBMGVdNuWDOX3ekY94Zz2SQvOna4Vr7Bl6djAaihvlsl+Wb6FQHtSRRh1xzmvPPpHCN/ anaIQxRm+l3xCVq8LbzL7yo3fucIRqpT5g9FxAQL8mxO4NbHvw7l4KoeNVMDUiiEzhIF NvMg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:references:in-reply-to:message-id:date :subject:cc:to:from; bh=BD5r2u+jaH5bBURuscayM57RDNOWS3zcJZnWNXP1I04=; b=r8jqKDjQJk9N9U810nolVfOxmST25BHNzFqCKsbnAoqNkHW+pRSV2UpN8/Ge/J3vGp 3JIyeEtSCbEZiNUkBh6DsIzR+Ps7iAjsRti0UtpAwksGt+di457cg7WKyWk2iNovAGOR FC0vqUZT8ht8Y66Hf9bTuugTTxigyMu8j8zhpSHrRIvM+1MtWRclCceYFamnmCEnZCHg 6Ht3GviSCD1Ajh89m5p3vJsWTLIHJ0ODMo3+XD5orSQ2QX2r9BN7LaISgyShgtWmGG4N KlanmO+INPJMX5vjKLcHJki3O4nZV2tFHjXhA3vRQ/HGXASD2BgEd4HtIkuGANYAUha6 cdiQ== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id 17-v6si12225495pgx.286.2018.09.08.07.30.43; Sat, 08 Sep 2018 07:30:44 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727578AbeIHTQk (ORCPT + 32 others); Sat, 8 Sep 2018 15:16:40 -0400 Received: from mout.kundenserver.de ([212.227.126.130]:44743 "EHLO mout.kundenserver.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726351AbeIHTQj (ORCPT ); Sat, 8 Sep 2018 15:16:39 -0400 Received: from wuerfel.lan ([109.193.40.16]) by mrelayeu.kundenserver.de (mreue011 [212.227.15.129]) with ESMTPA (Nemesis) id 1Mzhzd-1fc9Ql2W1Z-00vgsF; Sat, 08 Sep 2018 16:30:38 +0200 From: Arnd Bergmann To: viro@zeniv.linux.org.uk Cc: Arnd Bergmann , linux-fsdevel@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH 05/11] compat_ioctl: remove IGNORE_IOCTL() Date: Sat, 8 Sep 2018 16:28:11 +0200 Message-Id: <20180908142837.2819693-5-arnd@arndb.de> X-Mailer: git-send-email 2.18.0 In-Reply-To: <20180908142837.2819693-1-arnd@arndb.de> References: <20180908142837.2819693-1-arnd@arndb.de> X-Provags-ID: V03:K1:nGbJ5rDoHoRTqGmMjwVxk1EKcIjD3EJ4qLojhrz8TGe5tT+v4vw wShQKhuSiQodO+1Y/rvhQQgjbBFG15AfpNpwXsNKzDwJYzoro7wPQsg7PL/0+JHIIEYZYnt g3HYDhDVdkqNc8lxT7dZFgKeqv2SkcIvgcJKiXi8zPQhW/jDSJkEZrkFUxpeEoOHkIx1p45 6yAaspwr2GgTn84kY2izg== X-UI-Out-Filterresults: notjunk:1; V01:K0:OdVvqWONxx8=:KOdinIiFeW80teagBmcu9c Uj691wMWWSrTqvMjFTmBe02FhdKpw0F8AbYxxdqLevsZIs1+Qxhp/wEwpMWpIVjUoLwaZvO9j Go9Wa4UZU34AnqZ68Ko8r/7B9zoQ0vIphOqsCvH2vHwBxq1zR13lu2xyzf3WfwBbngzb4uGK/ ECs4rWABxwvZr+MBt6wETmljILAgXjb86JzKyrv2g39wilYC2I7rTaGSvoIXMcBdD5dPvbpwC XTZSSlOb1zX7Te9HuYVBW71GWwv2cPl4f+m8nRuyzX7WZtiHwxhDnSwwmmX9F34qOXQk3FVxs IuTn8qHSAHdNRcQ/SJpWchhW8UtFmiizyr2Cs4bZ3dHXCuZnCHGNBFM/uCZszr7sVLTd7RPrz qxnFO/D8yPkzgXq6HkkqhkVnydv0LWhmttmFkRD4Y/0yYyFdpFCPwD9MuI5M1QXyLS1l/GMb9 qpKbViThyCzbKpy3MiZqzumrdUsAS9Cffqsk7P/gmDoMl8GVBZGN2NOeR4lBTVsq40UC5CT9Y 2x/jVkz4ze3rmX5nIDt1Ex+2VJhhi9vwvjLEpdmxBicQdvuBB1CvC9fhndg+uj90AKeT8mJPc mlQtIOhATBWfmpHS26tMlT9DNfHAw4m5dgyU1Z4EZbRyuio49pdxZo/W0lnh2/JOU/LF7paab rfwF1bsvbN1TanbDngbYB+0G3D8iFkiZa725mDpDQs4YyMBMryhNgEElTQnaOn2vM5Mo= Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Since commit 07d106d0a33d ("vfs: fix up ENOIOCTLCMD error handling"), we don't warn about unhandled compat-ioctl command code any more, but just return the same error that a native file descriptor returns when there is no handler. This means the IGNORE_IOCTL() annotations are completely useless and can all be removed. TIOCSTART/TIOCSTOP and KDGHWCLK/KDSHWCLK fall into the same category, but for some reason were listed as COMPATIBLE_IOCTL(). Signed-off-by: Arnd Bergmann --- fs/compat_ioctl.c | 56 ----------------------------------------------- 1 file changed, 56 deletions(-) -- 2.18.0 diff --git a/fs/compat_ioctl.c b/fs/compat_ioctl.c index 7d8c5722fd0a..b56a3842d61d 100644 --- a/fs/compat_ioctl.c +++ b/fs/compat_ioctl.c @@ -463,20 +463,7 @@ static int compat_ioctl_preallocate(struct file *file, #define XFORM(i) (((i) ^ ((i) << 27) ^ ((i) << 17)) & 0xffffffff) #define COMPATIBLE_IOCTL(cmd) XFORM((u32)cmd), -/* ioctl should not be warned about even if it's not implemented. - Valid reasons to use this: - - It is implemented with ->compat_ioctl on some device, but programs - call it on others too. - - The ioctl is not implemented in the native kernel, but programs - call it commonly anyways. - Most other reasons are not valid. */ -#define IGNORE_IOCTL(cmd) COMPATIBLE_IOCTL(cmd) - static unsigned int ioctl_pointer[] = { -/* compatible ioctls first */ -COMPATIBLE_IOCTL(0x4B50) /* KDGHWCLK - not in the kernel, but don't complain */ -COMPATIBLE_IOCTL(0x4B51) /* KDSHWCLK - not in the kernel, but don't complain */ - /* Big T */ COMPATIBLE_IOCTL(TCGETA) COMPATIBLE_IOCTL(TCSETA) @@ -553,9 +540,6 @@ COMPATIBLE_IOCTL(SCSI_IOCTL_SEND_COMMAND) COMPATIBLE_IOCTL(SCSI_IOCTL_PROBE_HOST) COMPATIBLE_IOCTL(SCSI_IOCTL_GET_PCI) #endif -/* Big V (don't complain on serial console) */ -IGNORE_IOCTL(VT_OPENQRY) -IGNORE_IOCTL(VT_GETMODE) /* * These two are only for the sbus rtc driver, but * hwclock tries them on every rtc device first when @@ -569,11 +553,6 @@ COMPATIBLE_IOCTL(MTIOCTOP) /* Socket level stuff */ COMPATIBLE_IOCTL(FIOQSIZE) #ifdef CONFIG_BLOCK -/* md calls this on random blockdevs */ -IGNORE_IOCTL(RAID_VERSION) -/* qemu/qemu-img might call these two on plain files for probing */ -IGNORE_IOCTL(CDROM_DRIVE_STATUS) -IGNORE_IOCTL(FDGETPRM32) /* SG stuff */ COMPATIBLE_IOCTL(SG_SET_TIMEOUT) COMPATIBLE_IOCTL(SG_GET_TIMEOUT) @@ -684,41 +663,6 @@ COMPATIBLE_IOCTL(JSIOCGNAME(0)) COMPATIBLE_IOCTL(TIOCGLTC) COMPATIBLE_IOCTL(TIOCSLTC) #endif -#ifdef TIOCSTART -/* - * For these two we have definitions in ioctls.h and/or termios.h on - * some architectures but no actual implemention. Some applications - * like bash call them if they are defined in the headers, so we provide - * entries here to avoid syslog message spew. - */ -COMPATIBLE_IOCTL(TIOCSTART) -COMPATIBLE_IOCTL(TIOCSTOP) -#endif - -/* fat 'r' ioctls. These are handled by fat with ->compat_ioctl, - but we don't want warnings on other file systems. So declare - them as compatible here. */ -#define VFAT_IOCTL_READDIR_BOTH32 _IOR('r', 1, struct compat_dirent[2]) -#define VFAT_IOCTL_READDIR_SHORT32 _IOR('r', 2, struct compat_dirent[2]) - -IGNORE_IOCTL(VFAT_IOCTL_READDIR_BOTH32) -IGNORE_IOCTL(VFAT_IOCTL_READDIR_SHORT32) - -#ifdef CONFIG_SPARC -/* Sparc framebuffers, handled in sbusfb_compat_ioctl() */ -IGNORE_IOCTL(FBIOGTYPE) -IGNORE_IOCTL(FBIOSATTR) -IGNORE_IOCTL(FBIOGATTR) -IGNORE_IOCTL(FBIOSVIDEO) -IGNORE_IOCTL(FBIOGVIDEO) -IGNORE_IOCTL(FBIOSCURPOS) -IGNORE_IOCTL(FBIOGCURPOS) -IGNORE_IOCTL(FBIOGCURMAX) -IGNORE_IOCTL(FBIOPUTCMAP32) -IGNORE_IOCTL(FBIOGETCMAP32) -IGNORE_IOCTL(FBIOSCURSOR32) -IGNORE_IOCTL(FBIOGCURSOR32) -#endif }; /* From patchwork Sat Sep 8 14:28:12 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Arnd Bergmann X-Patchwork-Id: 146238 Delivered-To: patch@linaro.org Received: by 2002:a2e:1648:0:0:0:0:0 with SMTP id 8-v6csp627377ljw; Sat, 8 Sep 2018 07:31:25 -0700 (PDT) X-Google-Smtp-Source: ANB0Vda6+u0D9peiJ4z/MZAzHFvEWLnAVCFLecqYCMndtixzbKlhphMPzmV+q03F+f5G4GhEQ3AQ X-Received: by 2002:a17:902:988a:: with SMTP id s10-v6mr12832670plp.200.1536417085448; Sat, 08 Sep 2018 07:31:25 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1536417085; cv=none; d=google.com; s=arc-20160816; b=fqEntJqLv9jzc+lZKhF1FGS7or78OlucSa/7heTSTYt8hgBS4UmHRN4kLyCrkWlmKi w84oEWQVHCjRB2TTQDRN6lPlqZ9hMOHZg0qzVWWXidRF+4rmAcPfubuyxoVzCF7WWPpS lLvs7KoJdvxqjLNccG1MvKOX5XGgge2zlcbB7nubf3BNNkVHTZ9LSnEVy11rXZeZA+GR bDF1p/HiKsVHdOVUk+OnuWXEn7HLLGmExrtarjh/CwGedF9t7smw4lKw+epqiuCa3oQD IeITuBQOS88Mkcyk5ikAr/a0u6VK54l/598WfvCzOw0QYSFHQmqBvF9cdAc8IQV+emPG 3yuw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:references:in-reply-to:message-id:date :subject:cc:to:from; bh=a+K+X5qprXR74PjWMhPK5scXnMhCf7KT9PQtumAsWjE=; b=FpgKB+KpTNsd9XwR8dt5Ah0zaFZ2AdzdUoSajpW0dwmerk0YlaZGqPxVv9GQlGX/a2 CBndU18dtynF6isFB/eJaKDWNbo/InMOgVnQ0Qqiu4RlnyY69HmdtUfxDdgTrkI4N/hr oIx440OGolDkTCPALvLnHfhqYvJihxYfPsycDEecI150jgbvYiAjbSFWwI6Pa+wSAKnN lM3aH0TVFMqgpeT8Met7yOLuU+rxVx2VO9pcqnPJUzgoYSRaPBry5NN1qAhnvMvRxFz1 jxZ1f/Y1ITrBhzA/OAho3ewQI8f2zfh+Dujo9ZZTm2vhYniuODEH/PLzR5PJ5cp2Y+9c OfUA== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id l6-v6si11294985pfc.298.2018.09.08.07.31.25; Sat, 08 Sep 2018 07:31:25 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727682AbeIHTRW (ORCPT + 32 others); Sat, 8 Sep 2018 15:17:22 -0400 Received: from mout.kundenserver.de ([212.227.126.134]:35157 "EHLO mout.kundenserver.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727009AbeIHTRW (ORCPT ); Sat, 8 Sep 2018 15:17:22 -0400 Received: from wuerfel.lan ([109.193.40.16]) by mrelayeu.kundenserver.de (mreue011 [212.227.15.129]) with ESMTPA (Nemesis) id 1Mum2d-1fg1Jv33Jr-00rrOL; Sat, 08 Sep 2018 16:31:16 +0200 From: Arnd Bergmann To: viro@zeniv.linux.org.uk Cc: Arnd Bergmann , "Theodore Ts'o" , Greg Kroah-Hartman , linux-kernel@vger.kernel.org, linux-fsdevel@vger.kernel.org Subject: [PATCH 06/11] compat_ioctl: remove /dev/random commands Date: Sat, 8 Sep 2018 16:28:12 +0200 Message-Id: <20180908142837.2819693-6-arnd@arndb.de> X-Mailer: git-send-email 2.18.0 In-Reply-To: <20180908142837.2819693-1-arnd@arndb.de> References: <20180908142837.2819693-1-arnd@arndb.de> X-Provags-ID: V03:K1:aj9N/Luw1AgvpyHqFjV+g2BVt9SmQDi1RBBVWq/UXeUyPqlGStR /6q8X4FurUmI69zE9AQv50siBmmPxPQrLpywDCyTYvYaof6kCkUtH82PYfXu4YDPhpepNHy hOnac0kSL4cRiGT6opE22cuY3OqFJyTXqmiIdu9QGevCguoZ2io/nkvHw0r0uCs1QsQqK7C /JRNr7SOwQ8tdku1OafmA== X-UI-Out-Filterresults: notjunk:1; V01:K0:VCdWvQt2xfM=:lk2BnzLE5H9lWOjLg2MqeM rBZDVqTB5qxaxwWmlgL3bDVaPOe+LTVuUA/PCtu/Gs0JMsZCiDjD2p2fBt+nHnlafA9jBnXBg /zC6tTC/dZaMdb9jbGg4V9tZLKtYLgffy0yfDO6xT34P/iyc8eycOl4b9XryOTxBAKTCbrMEP 2Vq5afSIArd6k3HDbzDba0aswtojUNNbXi3lJb8q22GddmUiRIVYsjwLN+j/QoBD+rxd3zGN2 PgrfURoFbbJIo6p4Rg8ytwxL/srNxzbNCU/SIRPhylly+GKRyKxsyUZT0sEdg1WyDeFXQ+FoM jzbuNuQkWKf48lDaG2bfeQ06mg5d0H+ln42SWLQ7DdUmSF/azYRIA1yqM4nPr7VnU3MLes6X3 xuhWtwOjr24Z10B4z2Q9e60eDH3T5HQ1N4pUh5vdKQbDguq0A97d4vTaxRDv0oFPfzy7I3w0f b+tignH1npdju6LuBO7x/fWFq3HltOGCf5GgVTCu7eB9uV5Hvrjk8hhPaJsHO1aGffIhMOmDi 6ySWUq7E78EnNlgdzgH1jWKvVXiFdfIde1inuZLdT7KG5ERCR3UxzMinQFcML5JI5AfTpsITH QWA7M6WUxkD0n5d18E6G/qHjAoiN4ZZlpMbMo1EkabJFKm0YuJj+5OA4pGpifYFnmzwbUCNyC BdBzSRMiLUMzhwy1RjneNJsmPs50UGXYWZyGtKm6aYd8SKeUc0wulWjH8uxQ1TWE2neI= Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org These are all handled by the random driver, so instead of listing each ioctl, we can just use the same function to deal with both native and compat commands. Signed-off-by: Arnd Bergmann --- drivers/char/random.c | 1 + fs/compat_ioctl.c | 7 ------- 2 files changed, 1 insertion(+), 7 deletions(-) -- 2.18.0 diff --git a/drivers/char/random.c b/drivers/char/random.c index bf5f99fc36f1..103abf82444a 100644 --- a/drivers/char/random.c +++ b/drivers/char/random.c @@ -2021,6 +2021,7 @@ const struct file_operations random_fops = { .write = random_write, .poll = random_poll, .unlocked_ioctl = random_ioctl, + .compat_ioctl = random_ioctl, .fasync = random_fasync, .llseek = noop_llseek, }; diff --git a/fs/compat_ioctl.c b/fs/compat_ioctl.c index b56a3842d61d..eb29188d1dbb 100644 --- a/fs/compat_ioctl.c +++ b/fs/compat_ioctl.c @@ -594,13 +594,6 @@ COMPATIBLE_IOCTL(WDIOC_SETTIMEOUT) COMPATIBLE_IOCTL(WDIOC_GETTIMEOUT) COMPATIBLE_IOCTL(WDIOC_SETPRETIMEOUT) COMPATIBLE_IOCTL(WDIOC_GETPRETIMEOUT) -/* Big R */ -COMPATIBLE_IOCTL(RNDGETENTCNT) -COMPATIBLE_IOCTL(RNDADDTOENTCNT) -COMPATIBLE_IOCTL(RNDGETPOOL) -COMPATIBLE_IOCTL(RNDADDENTROPY) -COMPATIBLE_IOCTL(RNDZAPENTCNT) -COMPATIBLE_IOCTL(RNDCLEARPOOL) /* Bluetooth */ COMPATIBLE_IOCTL(HCIDEVUP) COMPATIBLE_IOCTL(HCIDEVDOWN) From patchwork Sat Sep 8 14:28:13 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Arnd Bergmann X-Patchwork-Id: 146239 Delivered-To: patch@linaro.org Received: by 2002:a2e:1648:0:0:0:0:0 with SMTP id 8-v6csp627663ljw; Sat, 8 Sep 2018 07:31:42 -0700 (PDT) X-Google-Smtp-Source: ANB0VdayrwZIinJ29YbrdM5gl/cv/YRzFnPT+hSwNSAEX7K3biBqQeIaHA9ppPoDtOkwWQC5LC9G X-Received: by 2002:a63:6c89:: with SMTP id h131-v6mr13478053pgc.237.1536417102337; Sat, 08 Sep 2018 07:31:42 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1536417102; cv=none; d=google.com; s=arc-20160816; b=M/1YddFkOkku3xu3yXW5/iQZRMPSJPRH689S1qZBLtOI3qjfr5pKzqG6uuPep272Mz xJOT1HURoWLS7+eP4HPEZxODhjEWEMGUuco1gjzTIgx3ThaQKUtgIgpZU2i52ofZu2q7 ffYPJR7GI6wS5AOkECL2+4uyjRNDKHtvcT90o6T68MICG9rk5wui2+PUr8pqnlQG1z2i Rr5w9CZ4lTH+yPQ0VcvL4Pco475JxYV/vz1W2/D8i1MXWIxXqbl+N9BHMJ5YKVgbHNZ/ 0cvPOhsHpUhbuC22b77M1hkFxvfNCp3hWUKg2UJBvu9jgzSN9QZRp/VcUDtaPSv49BDz jJkQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:references:in-reply-to:message-id:date :subject:cc:to:from; bh=nEs/EXsZ1ZF46QtV1Ll5Z66eBtAmzKVNQtMHfjtw1mE=; b=C0bSqn6ApncOUwGFNENfoMzJ9w1S7NOT0802IhjqK2mz/vKqgGxbW0pyb1di6h8vUY jaQSUNdUvcVoMR9E3GrPBJ74dX2EM67tYnIHluxu+Mr+E2iGfdKSl9QASN4PGdFoISnV 36i20nBXJYSnNegtF2RnxN5bQnpwKVqhXy03H9MyTRgZT6XXTmYWotjMeQdxcNPTk7Af wmIFkcAMCbfhG4UajAwBl/IvdrSg+27HmaqCqFbncUc56pbGgPpQ1vhXyrC9Nao6+i6+ IzV12QrcHRtNiqqDmhUrRodXWjvks/T1wyvajlKEzyh1Oy79ADEBIioIBqEvAI7ksheP pXfQ== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id d130-v6si11512611pfg.257.2018.09.08.07.31.42; Sat, 08 Sep 2018 07:31:42 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727701AbeIHTRj (ORCPT + 32 others); Sat, 8 Sep 2018 15:17:39 -0400 Received: from mout.kundenserver.de ([212.227.126.130]:34378 "EHLO mout.kundenserver.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727009AbeIHTRj (ORCPT ); Sat, 8 Sep 2018 15:17:39 -0400 Received: from wuerfel.lan ([109.193.40.16]) by mrelayeu.kundenserver.de (mreue011 [212.227.15.129]) with ESMTPA (Nemesis) id 1M1HuU-1g0IAC2sPq-002m0e; Sat, 08 Sep 2018 16:31:38 +0200 From: Arnd Bergmann To: viro@zeniv.linux.org.uk Cc: Arnd Bergmann , linux-fsdevel@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH 07/11] compat_ioctl: remove joystick ioctl translation Date: Sat, 8 Sep 2018 16:28:13 +0200 Message-Id: <20180908142837.2819693-7-arnd@arndb.de> X-Mailer: git-send-email 2.18.0 In-Reply-To: <20180908142837.2819693-1-arnd@arndb.de> References: <20180908142837.2819693-1-arnd@arndb.de> X-Provags-ID: V03:K1:wzPDog2sf4LNWniMkNTBPh+9VsaUDQDMSz61f4KlH9gIoo3lROa ZWAcpZN+1qFk+2NazzedX63oqEE/GGGabgVlemlfNwj+yClqpb/SFcSxx51eziD6ugrVhpQ RbsCG8MNGr+vHax24qVphlSvVKh8CKCxTFYrgvRmoma7BSP71E80ZRJLt3N1rMxGhLH+kov edox9FFrWg0GH9nfMjPKg== X-UI-Out-Filterresults: notjunk:1; V01:K0:5zUYGzFksIY=:QXLXW/sNKeSUfKwP9Stk2J 316Iiawm1j/ia7aCcbhk6/ygop1+q44gPy4aWRx3mad3O1oG+Wr5OlFjh9/ra6OU/oNDQoa/K ZaRpsHPqigN3w8bcZ1ugkO1XjLmIL7Jzq24CzA2zU+qvAluwuRnsjTb/+BeP4pHNGQcNi1IvW 7FW4X1WHEa3ikyD1OzduxqzU0+zYuyfUOQOHepB1ofv8L7hXt1kOSRBwNgo8lDFE5m92lA+1M rq5dC8DUIaQijgBya25QJTY5pogpAuhM8SMx34SOKt6eZKM9k2JECyrVeK+BtDwgTmfxqqFtS wu3LPnyyo0qJhV+CygQj/hGF5KCwhNu9U48xczTwHmE+w9PfkuPKZeSoBQ/vu9YtidFPKwnnd 1sZQvSOWG78uzuFbS/R/8rhrTIU9mxG6Y5Si97MVwf4nJGtUXJDauFMXzUa8zgTQEaC/j19q3 8E5lc9Y8ZtBYqmUy/j0K7AcqqU4ij2FUVZJtCRIGSab4FQD006+I27MNzQDD+V8XuF23+xmSZ M31m8GodBlsmQ1U05XcigFRyyYJvImCwmNkAAFo6MVk5bcEtwoECG6IXhhY21vQmF9pvLnHM3 C5IWvu6EC3KnMgKTbVN1fGkekUJG9PUZlYSihgCkxEFf/x4GbkBK2eLYXbtfLB0fIc/aopMb1 hToOxAwPoPpHbslnJt/EzXcZABztbZsJgigl1Skxn1Q8Ys9Ym6WFW3oCljqdWndwd7dM= Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org The joystick driver already handles these just fine, so the entries in the table are not needed any more. Signed-off-by: Arnd Bergmann --- fs/compat_ioctl.c | 8 -------- 1 file changed, 8 deletions(-) -- 2.18.0 diff --git a/fs/compat_ioctl.c b/fs/compat_ioctl.c index eb29188d1dbb..23c0406d8b30 100644 --- a/fs/compat_ioctl.c +++ b/fs/compat_ioctl.c @@ -11,8 +11,6 @@ * ioctls. */ -#include - #include #include #include @@ -646,12 +644,6 @@ COMPATIBLE_IOCTL(PCIIOC_CONTROLLER) COMPATIBLE_IOCTL(PCIIOC_MMAP_IS_IO) COMPATIBLE_IOCTL(PCIIOC_MMAP_IS_MEM) COMPATIBLE_IOCTL(PCIIOC_WRITE_COMBINE) -/* joystick */ -COMPATIBLE_IOCTL(JSIOCGVERSION) -COMPATIBLE_IOCTL(JSIOCGAXES) -COMPATIBLE_IOCTL(JSIOCGBUTTONS) -COMPATIBLE_IOCTL(JSIOCGNAME(0)) - #ifdef TIOCGLTC COMPATIBLE_IOCTL(TIOCGLTC) COMPATIBLE_IOCTL(TIOCSLTC) From patchwork Sat Sep 8 14:28:14 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Arnd Bergmann X-Patchwork-Id: 146240 Delivered-To: patch@linaro.org Received: by 2002:a2e:1648:0:0:0:0:0 with SMTP id 8-v6csp627867ljw; Sat, 8 Sep 2018 07:31:56 -0700 (PDT) X-Google-Smtp-Source: ANB0VdaOFT+U1neMPvgeTMghicHQPHh0oxmtsAQIzAscY0Ud4HtkLoubpmAAqM67GFgCnpGzPgUf X-Received: by 2002:a62:7d8d:: with SMTP id y135-v6mr13896720pfc.259.1536417116559; Sat, 08 Sep 2018 07:31:56 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1536417116; cv=none; d=google.com; s=arc-20160816; b=w4854NABhXkHVeswKkZlz2S49ZYAjdYJyrkCjU1g0FHbHz/3O4LCaJ5UBbA+RijvvS Di/cv21V8PexIeiL5J+X0M0FivT1L21XxVWM1BlKUW0MXkgeSr+m5iFSk5wp4G4VWN/v WIXBIj9vL6SfTN7u83Ghf/rcwU9WpMYbPHB4BHEPZ6DdcoyJrbxMkjSkTFMAImtDJh3X qhX56oBZ+WEkE4BGteZFZgthGQz9IVpJ/Y831KR7kchcWsPdITcJoIbxFBaOTe3CGZWe ThXy0mx2bs3gVl0L+WFlTDJeAAICCH/ncnJLJ8FYu9FBbzk2/4DrYD2UAybeDqZywmS9 DTYw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:references:in-reply-to:message-id:date :subject:cc:to:from; bh=GHIr2lYzZeqX1OWd3qjHHhKYE/+ZvO23EAKVdd/STOE=; b=mIXiQEGtBFqRwpDN1nAfnC/ZAQp7EB+q4DxOO1kS9W+965EK/lCvoSnfc1XrgHnQNj nCTdQFgEwK8qcS9MEyQlqMK0KYNbvmLb0OHKPksekG2sUuKUu//fJollQgHkBAb/7gFM x6cLjOHUxRP3KBr6Gk/fzZblV+Ilt818e+IXTMetSEVMA1NyCqZnWb+QOVZo7B0GzJfG JuiVqwb0R1LtTx+yhMhaRn7/1lE156D+w6zuYq5n6HGPk8zUdjj45Do4k0fseemwwMvr hePlDFPwpY9iqvyr5boSpZgNEwcsTUtIsLCy/O/XVFU8CFgurIqEO1nA3RuusfL3ip8E sFkA== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id d20-v6si12222059pgj.535.2018.09.08.07.31.56; Sat, 08 Sep 2018 07:31:56 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727707AbeIHTRx (ORCPT + 32 others); Sat, 8 Sep 2018 15:17:53 -0400 Received: from mout.kundenserver.de ([212.227.126.133]:53125 "EHLO mout.kundenserver.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726498AbeIHTRx (ORCPT ); Sat, 8 Sep 2018 15:17:53 -0400 Received: from wuerfel.lan ([109.193.40.16]) by mrelayeu.kundenserver.de (mreue011 [212.227.15.129]) with ESMTPA (Nemesis) id 1MdNse-1fPJWa0qJM-00ZMfa; Sat, 08 Sep 2018 16:31:52 +0200 From: Arnd Bergmann To: viro@zeniv.linux.org.uk Cc: Arnd Bergmann , linux-fsdevel@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH 08/11] compat_ioctl: remove PCI ioctl translation Date: Sat, 8 Sep 2018 16:28:14 +0200 Message-Id: <20180908142837.2819693-8-arnd@arndb.de> X-Mailer: git-send-email 2.18.0 In-Reply-To: <20180908142837.2819693-1-arnd@arndb.de> References: <20180908142837.2819693-1-arnd@arndb.de> X-Provags-ID: V03:K1:5i0atZbPU/6NU8g3lethk2tgTnaPSx3cL96LTyt/iN9OTM4WgXC 67Zz3stSmOARnU8rh1TnOzrc0bhhhVx4WUU8a2z0BXswwQmgqStzU0W4rG4qkbejKns8HdE qG2aByc4kotLE79J2Q1ELscEyCzqFQyQNCyFfJx2rdVZpC0w1InNg8r5smujCUqxnhK0dij 4qvOmSKwvaXXAwTO4RFrQ== X-UI-Out-Filterresults: notjunk:1; V01:K0:B+APLvWVNGg=:9uBcQdvy1Q/zEmVZ5M8znf wfwaJlo15jDnM589Yagx84SpsWTIZzjneA0fVQOfkg3pxO2JGLBliym0DhC24c+MqADOcPtb0 p/awAWYA9wi7Ou+XvYE3PPPm2S6ykgTVmQu93hPWN+1Y7PpWjh/g6yKfOnkIMxNHlsG0xL8vQ CTl8/wYz+3LgeviRg8AWmyW9dlq23aom/bu7iL4UiI6tQ2rcRahm58508hSCE93ZeaD1LG/W/ nOFA2k9tCca8Mxzfdz4e9tAIjN9QzyZIzgU9Djzs/klYu3M1i5wxfZxDys5yc3cSC8eOKQyV8 lcB9cJYDsB/b6EbwsY6HVUZrTxv97i7W3rMWok1MfYiUkHySWkb6N+sJqJNXdHPiuIwK5RNX/ 6ll2jx8Ftgy5Yy3n8NKFgvbwK78/m/BQBwusKB/0frBqzNrq1CGb+MLgID8/BPTE9he3YQJ08 AH5l2s7816QY/Z/DwYiJzGf+llDCFcBl7po2kH/Zc33yMrxJ9/3cHc8eKPzPcuG8me10fIAqt uWR1bebRHMmvwcKInNovYgve87ZhJ5fnEm269rxHDynBs22HQrxfAIi4wC6he5TMjwHp004Qc KZ9I/dzLxExdKhDjyoaiev/EZbyI8cxvJR9mgQVJ0A64JnTDC2iPSaXcFXrLHUqMYQ+r8AVM1 ouz/k1v05oTI52hnmCy72GQw1vyTVHFtyRfh2zjEKqYfTOQFuq8JGYgrUgjfcPPUySE0= Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org The /proc/pci/ implementation already handles these just fine, so the entries in the table are not needed any more. Signed-off-by: Arnd Bergmann --- fs/compat_ioctl.c | 5 ----- 1 file changed, 5 deletions(-) -- 2.18.0 diff --git a/fs/compat_ioctl.c b/fs/compat_ioctl.c index 23c0406d8b30..28ebff2d1799 100644 --- a/fs/compat_ioctl.c +++ b/fs/compat_ioctl.c @@ -44,7 +44,6 @@ #include #include #include -#include #include #include #include @@ -640,10 +639,6 @@ COMPATIBLE_IOCTL(HIDPGETCONNINFO) /* Misc. */ COMPATIBLE_IOCTL(0x41545900) /* ATYIO_CLKR */ COMPATIBLE_IOCTL(0x41545901) /* ATYIO_CLKW */ -COMPATIBLE_IOCTL(PCIIOC_CONTROLLER) -COMPATIBLE_IOCTL(PCIIOC_MMAP_IS_IO) -COMPATIBLE_IOCTL(PCIIOC_MMAP_IS_MEM) -COMPATIBLE_IOCTL(PCIIOC_WRITE_COMBINE) #ifdef TIOCGLTC COMPATIBLE_IOCTL(TIOCGLTC) COMPATIBLE_IOCTL(TIOCSLTC) From patchwork Sat Sep 8 14:28:15 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Arnd Bergmann X-Patchwork-Id: 146241 Delivered-To: patch@linaro.org Received: by 2002:a2e:1648:0:0:0:0:0 with SMTP id 8-v6csp628081ljw; Sat, 8 Sep 2018 07:32:12 -0700 (PDT) X-Google-Smtp-Source: ANB0VdbKzZPxiBcI1qDPrYCZWSd7F5PhWDjbAjtzvhHG2R3gRq+3GScZ4fx2udtb9ludLavoHoZ3 X-Received: by 2002:a65:41c6:: with SMTP id b6-v6mr13707328pgq.174.1536417131902; Sat, 08 Sep 2018 07:32:11 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1536417131; cv=none; d=google.com; s=arc-20160816; b=KhjulAcM0W+h6t95EtZG5g9lmiMW1FAd16CCMU4dYwXqC7q+5m3DEwBW4bi1Z3tJKD GU3tP0AeDvK3eAzlGDzx/Yfc+tBqaauA7HaJY8spdp5McAqfetf/d6wnA7SiU2W+atVD 2F+V0wL8qoAYOoYybqBNQ9cYuUV7PTNP4/AxKfK8eSmtFU59kuDd02+tBGFoCW7NfQZ/ RaSIkoKYGtAfqxEg4FHdX1HgSoIb62T8kJpFWvgzryFF74GxSWCRo6zRIIowEs/L03IN laQpJsCxB51oPuZVHoNc9tEhNthMqASSZWU3Ovdgvu2nCd4zJNnffilhdRFmmtiPvcoJ cA9g== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:references:in-reply-to:message-id:date :subject:cc:to:from; bh=nvGir8l+L8Wp6C8M5sELQIpnx7uZr7nQxfSElLv5yeY=; b=bdgPQuLfOJYXVHP7BrOd+ZRr/w2IN5iSUybKBeBAev9BB013RGwuut6fDae821PCUc 2RAFDZdnwybNttNwfP8HO4KIQcxP1c84793vn8Fd0FWXkaLqUKHfQTJJDT5m5JA2U5wx btm4qBvygq0UXq3iGQd7hkQkaC0Yyt/4QY/hJhHi/7q+AtpfEgLmTFvrWe+F7xfJZj86 VyQlnrLHfvbI831fVPPh9JRLc3ruOo7o9WD7GWgekhUKtU166e3E//zRXmsprV1R1eX+ 6q0SClp+X7xK/QlBms2ul31hZ1jdsm7ENrfD0SSsD/QJyzDRYPX63foe+gGLlxx0g8we uLmg== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id j64-v6si12126961pgc.88.2018.09.08.07.32.11; Sat, 08 Sep 2018 07:32:11 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727720AbeIHTSI (ORCPT + 32 others); Sat, 8 Sep 2018 15:18:08 -0400 Received: from mout.kundenserver.de ([212.227.126.131]:44931 "EHLO mout.kundenserver.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726498AbeIHTSI (ORCPT ); Sat, 8 Sep 2018 15:18:08 -0400 Received: from wuerfel.lan ([109.193.40.16]) by mrelayeu.kundenserver.de (mreue011 [212.227.15.129]) with ESMTPA (Nemesis) id 1M2NqA-1g1O6T0GWE-003rwK; Sat, 08 Sep 2018 16:32:07 +0200 From: Arnd Bergmann To: viro@zeniv.linux.org.uk Cc: Arnd Bergmann , linux-fsdevel@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH 09/11] compat_ioctl: remove /dev/raw ioctl translation Date: Sat, 8 Sep 2018 16:28:15 +0200 Message-Id: <20180908142837.2819693-9-arnd@arndb.de> X-Mailer: git-send-email 2.18.0 In-Reply-To: <20180908142837.2819693-1-arnd@arndb.de> References: <20180908142837.2819693-1-arnd@arndb.de> X-Provags-ID: V03:K1:igYwFt37Me/pBzU2cL5f50SU8QPyDjxHobFHBJxRdCx1SRjJQLQ hiIjs01dgrRvah7tGGbQsnWhIqUDZYUK9gybmYyjwlthMj96eKd6gE+NPNEtGvfTlW5sKkF e988tyZFCxgl1tduJgXZHXSxMNvZPtagM1lYlsINbQwFmBx21kkf3U9yYvZ90L6oxIcURRc 2USiZE1Hnxfq0eFZjJwEw== X-UI-Out-Filterresults: notjunk:1; V01:K0:LXDHlHckRH8=:mzkNgCsds9MEPVh/L/x6jR 7y3xeSQHCidanQRs+xk2iwRg1cL7XpWfsDAkO0zRlGWsJPoTppoNOL6PBEWyTA9xTBeF6Rs/T 4ys2req1TPD4vluzkXYE06UlX5olN5OBvkjWjtVpKUA1Gi3R22F+YeYdCqWutbhHOyIhdozlu z35C3mk6y7Gzgi/o2W6xNcMsKR4LRJ7vKbjkMILfxikDiNBqQhCGYwGDrwVjDAJIM1wFAwBy7 Wk+MuU+hi7jwwVCcgVtuclD8tECmu2iVdWsTV+GFhL5YIjLlZzJNYLKAfpReUULEo0QoyCTZL 7LGCpjCI4ysp6ckBJ+niQFCv6jFemgyfGkTK7dSLf6nBDsEDFaXMFaMu/v2kN7T8Up66G0MeT 24D1F5Ih7Zwigy8ZbOjo7f4vceOiUAMjcg0Ybr0EcJsgZ/DMZZbDFmYiMY78kQ0PiiXDTUZt9 cMzkC981IrIKuyRbbGcPDetSoxQ5U5WCRlU3pUfAck0L5EzhWD/rOUf1urthYb63vsH+kWcpK n2GzXXliGPgbCUh7M18Uf/eFdsC3R+idcmM0ZZxEFCKOEEClM7Iui92pF7LC2qZBJFpfA2A7D ZMu2lhI1ETB/6hvHs3xf5TOyoLBEayQVOY5KvoUipDBmEHRsXZPhJZyz2r80XCG1xLrfyupCv EhSlMZCt+DaDVsPeJSY6J1hvxzvCtDmgfmwq9SCjzTZ33vrruAjWDyaCDmLXGCClBEmg= Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org The /dev/rawX implementation already handles these just fine, so the entries in the table are not needed any more. Signed-off-by: Arnd Bergmann --- fs/compat_ioctl.c | 4 ---- 1 file changed, 4 deletions(-) -- 2.18.0 diff --git a/fs/compat_ioctl.c b/fs/compat_ioctl.c index 28ebff2d1799..e755802cd887 100644 --- a/fs/compat_ioctl.c +++ b/fs/compat_ioctl.c @@ -41,7 +41,6 @@ #include #include #include -#include #include #include #include @@ -577,9 +576,6 @@ COMPATIBLE_IOCTL(SG_GET_KEEP_ORPHAN) /* PPP stuff */ COMPATIBLE_IOCTL(PPPIOCGUNIT) COMPATIBLE_IOCTL(PPPIOCGCHAN) -/* Raw devices */ -COMPATIBLE_IOCTL(RAW_SETBIND) -COMPATIBLE_IOCTL(RAW_GETBIND) /* Watchdog */ COMPATIBLE_IOCTL(WDIOC_GETSUPPORT) COMPATIBLE_IOCTL(WDIOC_GETSTATUS) From patchwork Sat Sep 8 14:28:16 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Arnd Bergmann X-Patchwork-Id: 146242 Delivered-To: patch@linaro.org Received: by 2002:a2e:1648:0:0:0:0:0 with SMTP id 8-v6csp628267ljw; Sat, 8 Sep 2018 07:32:23 -0700 (PDT) X-Google-Smtp-Source: ANB0VdaWVJpktoqt8cfgknrD88ieb9QmU5dlV+oY23BO9WW0+V+XwtAdXd73cNrQVOp9ws7fk7/M X-Received: by 2002:a62:ee06:: with SMTP id e6-v6mr14297136pfi.2.1536417143802; Sat, 08 Sep 2018 07:32:23 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1536417143; cv=none; d=google.com; s=arc-20160816; b=I2o+3oReZUmmkCBS6B/y2vCPoETJhXvl9L/npD2mFSKph7WV9g1SsPsXhiWbKctdhl ItFVuoMESyelCEimeI4/pXB5lDGPgchRjpqbqpiq09R3fspoOtlApUtd5Mr4I6EZ12u5 n9AUrcaNfyqo2LXtWoTfjsfEFbBVjEMK7OW3X8nNfcnmx8Zsd0kqxGqg30xdXZRTtL3Q VUl0/xDuowm8bnJaYW/5sZK1zlWEo7F7nrtIAh6zbc+idJ3/Tz9SIskNFNSU2E+OyGb7 5IqWh5nDbkXfFf2xvT7H+xwGFbqHVxHytw0kqe/y1yPgmtISqHV9ezWzm2J+6saTRtCJ /zTw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:references:in-reply-to:message-id:date :subject:cc:to:from; bh=Dp+CUGKcTp2ODbXNlED6rffOXvRP72Zvtw5x5P3XneA=; b=YgSZkzf+AcFfYvF8XCJ3acUMq1hqzpwmfGknzjKNKafOrysjqYx5iycnlBCAiq3lAM rn9NLaym2osBmNqz4+UFfvrNs+xbzuUyVe3VQ7RwPzgSjkTzgB+92puJawEcuQtLyovw ao7/5/8EtoJsXi77ZTt122ckVJk+1bQ81jkJkjdctlNaQEdhm4tBSgv6RpxRlBVfWhBX Bfd9YzNIvs+0TUnY9q+IxVJNpTZ3+crkLmnGSKBVU8IaLpkmhwoyQ0d4UywbVT/9bQKY lslhr+NbQZZ3YaMKhoHiyA+85pCwsr7NoxY94O8YYDYywIG5gNOn93EXi41CPYqxII/6 68Rw== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id n10-v6si12361955pgf.415.2018.09.08.07.32.23; Sat, 08 Sep 2018 07:32:23 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727728AbeIHTSV (ORCPT + 32 others); Sat, 8 Sep 2018 15:18:21 -0400 Received: from mout.kundenserver.de ([212.227.126.187]:46757 "EHLO mout.kundenserver.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726498AbeIHTSV (ORCPT ); Sat, 8 Sep 2018 15:18:21 -0400 Received: from wuerfel.lan ([109.193.40.16]) by mrelayeu.kundenserver.de (mreue011 [212.227.15.129]) with ESMTPA (Nemesis) id 1M7sYM-1ftgSv3jta-004xrU; Sat, 08 Sep 2018 16:32:20 +0200 From: Arnd Bergmann To: viro@zeniv.linux.org.uk Cc: Arnd Bergmann , linux-fsdevel@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH 10/11] compat_ioctl: remove last RAID handling code Date: Sat, 8 Sep 2018 16:28:16 +0200 Message-Id: <20180908142837.2819693-10-arnd@arndb.de> X-Mailer: git-send-email 2.18.0 In-Reply-To: <20180908142837.2819693-1-arnd@arndb.de> References: <20180908142837.2819693-1-arnd@arndb.de> X-Provags-ID: V03:K1:iW7l/Gd5IQMh7nfRB2avxtImh6Fc3QsDzwqSE8CsNKg/ePQA3El vsnxK19XNvCGdRJlgqHCw8qR9tu67nekmJA0NhwUMaPudeCDp/RhL4t444f/KATXyLKZKmJ lNaFpBlrr/5zrrWu1k4rGlnBlAnbgTKOByJf/KWYljWidLjXd2s2PjpjIzWVBLoSPJ5sWYi y355Ts4qNTOIT/KOilbXg== X-UI-Out-Filterresults: notjunk:1; V01:K0:sC2n6bb9Lts=:wAD5c2VTEVHuJ8K8fvJJOD Pkm7DV4E8MXD0tSBVhZ8po58wHKmosjQ1VkeA5ADPgFozyMrAC5PRcvD9VRT7HO74hNx65sNB qdAJ2wsxQxqAXmoopcaCL2bbFH1jHV4ijCRLUyTRAwyxFwGoyyU15rbmrUabshOCsHAs13tDi 0F/Hzx1ONIwVZsIxD+yE9CNjli04nO7NuMvH2ldACLDK3apyK2J/lnc9wq4IsR8j+/uhlQEex GmfVNKv131g77qwtRlmM86hWyw7+OdyOdmGt/yFcHOEpPNq7LvjzPXy/7wkcr/uiMHxj21XwM vMk2Legm3MF568cyxATbupeVYqlKlZKO98uqm2y3Y4UJvP1aU+DxtRHqRaPDVJtnmeXw3J6wL +Hy1XBK7VEMgKgS1meODmWD0Af6LAlAvrMrf8o3dOinCgjMlViZxjlhqQfm2ej2HRRsmoWd32 VOcPlGU5VcWgsvOTXqwsscoasoNW9E9W0kUEtyRsXzePgzRVpagba7t6phEOE4LT3K4Tux6IK PB3RGoYEcNocW7MZjzCmW26WN2UnYyAexaxB8MxlsfCe50OP8QbvwJPIFZdcWPCy5uV2axgf5 +4a4m83kZCTRVqXnGoEfm1+VkVPtJC8XPC4olV3jrpj4/VnxJ22Tju6c/kdqBwbA215MQgJjF G48qnGO87Et7AGnykF1IdyJaxsTR8jTTtxJxdB++IYnEPjCrrzd7xJdWnLxM/CyY9G/8= Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Commit aa98aa31987a ("md: move compat_ioctl handling into md.c") already removed the COMPATIBLE_IOCTL() table entries and added a complete implementation, but a few lines got left behind and should also be removed here. Signed-off-by: Arnd Bergmann --- fs/compat_ioctl.c | 5 ----- 1 file changed, 5 deletions(-) -- 2.18.0 diff --git a/fs/compat_ioctl.c b/fs/compat_ioctl.c index e755802cd887..bb73d52f02a2 100644 --- a/fs/compat_ioctl.c +++ b/fs/compat_ioctl.c @@ -676,11 +676,6 @@ static long do_ioctl_trans(unsigned int cmd, case TCSBRKP: case TIOCMIWAIT: case TIOCSCTTY: - /* RAID */ - case HOT_REMOVE_DISK: - case HOT_ADD_DISK: - case SET_DISK_FAULTY: - case SET_BITMAP_FILE: return vfs_ioctl(file, cmd, arg); }