From patchwork Thu Apr 25 17:09:47 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?b?VmlsbGUgU3lyasOkbMOk?= X-Patchwork-Id: 2488881 Return-Path: X-Original-To: patchwork-dri-devel@patchwork.kernel.org Delivered-To: patchwork-process-083081@patchwork1.kernel.org Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) by patchwork1.kernel.org (Postfix) with ESMTP id E6C763FC64 for ; Thu, 25 Apr 2013 17:12:37 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id E18CCE65FE for ; Thu, 25 Apr 2013 10:12:37 -0700 (PDT) X-Original-To: dri-devel@lists.freedesktop.org Delivered-To: dri-devel@lists.freedesktop.org Received: from mga02.intel.com (mga02.intel.com [134.134.136.20]) by gabe.freedesktop.org (Postfix) with ESMTP id 1FFF4E620F for ; Thu, 25 Apr 2013 10:10:13 -0700 (PDT) Received: from orsmga002.jf.intel.com ([10.7.209.21]) by orsmga101.jf.intel.com with ESMTP; 25 Apr 2013 10:10:12 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="4.87,551,1363158000"; d="scan'208";a="325341539" Received: from stinkbox.fi.intel.com (HELO stinkbox) ([10.237.72.168]) by orsmga002.jf.intel.com with SMTP; 25 Apr 2013 10:09:48 -0700 Received: by stinkbox (sSMTP sendmail emulation); Thu, 25 Apr 2013 20:09:47 +0300 From: ville.syrjala@linux.intel.com To: dri-devel@lists.freedesktop.org Subject: [PATCH libdrm] Deprecate drmModeAttachMode and drmModeDetachMode Date: Thu, 25 Apr 2013 20:09:47 +0300 Message-Id: <1366909787-16981-1-git-send-email-ville.syrjala@linux.intel.com> X-Mailer: git-send-email 1.8.1.5 MIME-Version: 1.0 X-BeenThere: dri-devel@lists.freedesktop.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: Direct Rendering Infrastructure - Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: dri-devel-bounces+patchwork-dri-devel=patchwork.kernel.org@lists.freedesktop.org Errors-To: dri-devel-bounces+patchwork-dri-devel=patchwork.kernel.org@lists.freedesktop.org From: Ville Syrjälä The kernel no longer implements the ioctls, and they never did anything useful. Signed-off-by: Ville Syrjälä --- xf86drmMode.c | 16 ++++------------ xf86drmMode.h | 10 ++-------- 2 files changed, 6 insertions(+), 20 deletions(-) diff --git a/xf86drmMode.c b/xf86drmMode.c index f603ceb..74e074d 100644 --- a/xf86drmMode.c +++ b/xf86drmMode.c @@ -539,24 +539,16 @@ err_allocs: return r; } +/* deprecated */ int drmModeAttachMode(int fd, uint32_t connector_id, drmModeModeInfoPtr mode_info) { - struct drm_mode_mode_cmd res; - - memcpy(&res.mode, mode_info, sizeof(struct drm_mode_modeinfo)); - res.connector_id = connector_id; - - return DRM_IOCTL(fd, DRM_IOCTL_MODE_ATTACHMODE, &res); + return -EINVAL; } +/* deprecated */ int drmModeDetachMode(int fd, uint32_t connector_id, drmModeModeInfoPtr mode_info) { - struct drm_mode_mode_cmd res; - - memcpy(&res.mode, mode_info, sizeof(struct drm_mode_modeinfo)); - res.connector_id = connector_id; - - return DRM_IOCTL(fd, DRM_IOCTL_MODE_DETACHMODE, &res); + return -EINVAL; } diff --git a/xf86drmMode.h b/xf86drmMode.h index 8e40034..0f0c26b 100644 --- a/xf86drmMode.h +++ b/xf86drmMode.h @@ -398,15 +398,9 @@ drmModeEncoderPtr drmModeGetEncoder(int fd, uint32_t encoder_id); extern drmModeConnectorPtr drmModeGetConnector(int fd, uint32_t connectorId); -/** - * Attaches the given mode to an connector. - */ +/* deprecated */ extern int drmModeAttachMode(int fd, uint32_t connectorId, drmModeModeInfoPtr mode_info); - -/** - * Detaches a mode from the connector - * must be unused, by the given mode. - */ +/* deprecated */ extern int drmModeDetachMode(int fd, uint32_t connectorId, drmModeModeInfoPtr mode_info); extern drmModePropertyPtr drmModeGetProperty(int fd, uint32_t propertyId);