From owner-svn-src-head@freebsd.org Sat Feb 25 18:14:34 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 5F221CEC125; Sat, 25 Feb 2017 18:14:34 +0000 (UTC) (envelope-from oshogbo@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 125C4F56; Sat, 25 Feb 2017 18:14:34 +0000 (UTC) (envelope-from oshogbo@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v1PIEXeR071710; Sat, 25 Feb 2017 18:14:33 GMT (envelope-from oshogbo@FreeBSD.org) Received: (from oshogbo@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v1PIEX1R071707; Sat, 25 Feb 2017 18:14:33 GMT (envelope-from oshogbo@FreeBSD.org) Message-Id: <201702251814.v1PIEX1R071707@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: oshogbo set sender to oshogbo@FreeBSD.org using -f From: Mariusz Zaborski Date: Sat, 25 Feb 2017 18:14:33 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r314275 - in head/sys/boot/i386: boot2 common X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 25 Feb 2017 18:14:34 -0000 Author: oshogbo Date: Sat Feb 25 18:14:32 2017 New Revision: 314275 URL: https://svnweb.freebsd.org/changeset/base/314275 Log: Remove unused macro from common/drv.c. When we was compering it to code from boot2 it also looks like this code is buggy and boot2 was never updated to use this code. USE_XREAD flag is unused in boot2, and common/drv.c was never build with that flag. Reviewed by: jhb Differential Revision: https://reviews.freebsd.org/D9780 Modified: head/sys/boot/i386/boot2/Makefile head/sys/boot/i386/common/drv.c Modified: head/sys/boot/i386/boot2/Makefile ============================================================================== --- head/sys/boot/i386/boot2/Makefile Sat Feb 25 17:03:48 2017 (r314274) +++ head/sys/boot/i386/boot2/Makefile Sat Feb 25 18:14:32 2017 (r314275) @@ -25,7 +25,6 @@ BOOT2_UFS?= UFS1_AND_UFS2 CFLAGS= -fomit-frame-pointer \ -mrtd \ -mregparm=3 \ - -DUSE_XREAD \ -D${BOOT2_UFS} \ -DFLAGS=${BOOT_BOOT1_FLAGS} \ -DSIOPRT=${BOOT_COMCONSOLE_PORT} \ Modified: head/sys/boot/i386/common/drv.c ============================================================================== --- head/sys/boot/i386/common/drv.c Sat Feb 25 17:03:48 2017 (r314274) +++ head/sys/boot/i386/common/drv.c Sat Feb 25 18:14:32 2017 (r314275) @@ -25,9 +25,6 @@ __FBSDID("$FreeBSD$"); #include "util.h" #include "drv.h" #include "edd.h" -#ifdef USE_XREAD -#include "xreadorg.h" -#endif static struct edd_params params; @@ -50,9 +47,7 @@ drvsize(struct dsk *dskp) return (params.sectors); } -#ifndef USE_XREAD static struct edd_packet packet; -#endif int drvread(struct dsk *dskp, void *buf, daddr_t lba, unsigned nblk) @@ -61,7 +56,6 @@ drvread(struct dsk *dskp, void *buf, dad if (!OPT_CHECK(RBX_QUIET)) printf("%c\b", c = c << 8 | c >> 24); -#ifndef USE_XREAD packet.len = sizeof(struct edd_packet); packet.count = nblk; packet.off = VTOPOFF(buf); @@ -73,15 +67,6 @@ drvread(struct dsk *dskp, void *buf, dad v86.edx = dskp->drive; v86.ds = VTOPSEG(&packet); v86.esi = VTOPOFF(&packet); -#else /* USE_XREAD */ - v86.ctl = V86_ADDR | V86_CALLF | V86_FLAGS; - v86.addr = XREADORG; /* call to xread in boot1 */ - v86.es = VTOPSEG(buf); - v86.eax = lba; - v86.ebx = VTOPOFF(buf); - v86.ecx = lba >> 32; - v86.edx = nblk << 8 | dskp->drive; -#endif /* USE_XREAD */ v86int(); if (V86_CY(v86.efl)) { printf("%s: error %u lba %u\n",