From owner-svn-src-stable-8@FreeBSD.ORG Tue Sep 3 23:20:04 2013 Return-Path: Delivered-To: svn-src-stable-8@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTP id 879AC621; Tue, 3 Sep 2013 23:20:04 +0000 (UTC) (envelope-from markj@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mx1.freebsd.org (Postfix) with ESMTPS id 5A2B2247B; Tue, 3 Sep 2013 23:20:04 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.7/8.14.7) with ESMTP id r83NK4x9093069; Tue, 3 Sep 2013 23:20:04 GMT (envelope-from markj@svn.freebsd.org) Received: (from markj@localhost) by svn.freebsd.org (8.14.7/8.14.5/Submit) id r83NK4EV093068; Tue, 3 Sep 2013 23:20:04 GMT (envelope-from markj@svn.freebsd.org) Message-Id: <201309032320.r83NK4EV093068@svn.freebsd.org> From: Mark Johnston Date: Tue, 3 Sep 2013 23:20:04 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-8@freebsd.org Subject: svn commit: r255197 - stable/8/usr.bin/ldd X-SVN-Group: stable-8 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-stable-8@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for only the 8-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 03 Sep 2013 23:20:04 -0000 Author: markj Date: Tue Sep 3 23:20:03 2013 New Revision: 255197 URL: http://svnweb.freebsd.org/changeset/base/255197 Log: MFC r254018: Pass variables prefixed with both LD_ and LD_32_ to the run-time linker. This prevents unintentional execution of programs when running ldd(1) on 32-bit Linux binaries. Modified: stable/8/usr.bin/ldd/ldd.c Directory Properties: stable/8/usr.bin/ldd/ (props changed) Modified: stable/8/usr.bin/ldd/ldd.c ============================================================================== --- stable/8/usr.bin/ldd/ldd.c Tue Sep 3 23:17:18 2013 (r255196) +++ stable/8/usr.bin/ldd/ldd.c Tue Sep 3 23:20:03 2013 (r255197) @@ -49,12 +49,6 @@ __FBSDID("$FreeBSD$"); #include "extern.h" -#ifdef COMPAT_32BIT -#define LD_ "LD_32_" -#else -#define LD_ "LD_" -#endif - /* * 32-bit ELF data structures can only be used if the system header[s] declare * them. There is no official macro for determining whether they are declared, @@ -64,6 +58,16 @@ __FBSDID("$FreeBSD$"); #define ELF32_SUPPORTED #endif +#define LDD_SETENV(name, value, overwrite) do { \ + setenv("LD_" name, value, overwrite); \ + setenv("LD_32_" name, value, overwrite); \ +} while (0) + +#define LDD_UNSETENV(name) do { \ + unsetenv("LD_" name); \ + unsetenv("LD_32_" name); \ +} while (0) + static int is_executable(const char *fname, int fd, int *is_shlib, int *type); static void usage(void); @@ -82,7 +86,7 @@ execldd32(char *file, char *fmt1, char * char *argv[8]; int i, rval, status; - unsetenv(LD_ "TRACE_LOADED_OBJECTS"); + LDD_UNSETENV("TRACE_LOADED_OBJECTS"); rval = 0; i = 0; argv[i++] = strdup(_PATH_LDD32); @@ -121,7 +125,7 @@ execldd32(char *file, char *fmt1, char * } while (i--) free(argv[i]); - setenv(LD_ "TRACE_LOADED_OBJECTS", "yes", 1); + LDD_SETENV("TRACE_LOADED_OBJECTS", "yes", 1); return (rval); } #endif @@ -210,15 +214,15 @@ main(int argc, char *argv[]) } /* ld.so magic */ - setenv(LD_ "TRACE_LOADED_OBJECTS", "yes", 1); + LDD_SETENV("TRACE_LOADED_OBJECTS", "yes", 1); if (fmt1 != NULL) - setenv(LD_ "TRACE_LOADED_OBJECTS_FMT1", fmt1, 1); + LDD_SETENV("TRACE_LOADED_OBJECTS_FMT1", fmt1, 1); if (fmt2 != NULL) - setenv(LD_ "TRACE_LOADED_OBJECTS_FMT2", fmt2, 1); + LDD_SETENV("TRACE_LOADED_OBJECTS_FMT2", fmt2, 1); - setenv(LD_ "TRACE_LOADED_OBJECTS_PROGNAME", *argv, 1); + LDD_SETENV("TRACE_LOADED_OBJECTS_PROGNAME", *argv, 1); if (aflag) - setenv(LD_ "TRACE_LOADED_OBJECTS_ALL", "1", 1); + LDD_SETENV("TRACE_LOADED_OBJECTS_ALL", "1", 1); else if (fmt1 == NULL && fmt2 == NULL) /* Default formats */ printf("%s:\n", *argv); From owner-svn-src-stable-8@FreeBSD.ORG Thu Sep 5 20:34:58 2013 Return-Path: Delivered-To: svn-src-stable-8@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTP id B4E6E8CF; Thu, 5 Sep 2013 20:34:58 +0000 (UTC) (envelope-from joerg@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mx1.freebsd.org (Postfix) with ESMTPS id 8778C2EBF; Thu, 5 Sep 2013 20:34:58 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.7/8.14.7) with ESMTP id r85KYwcE090552; Thu, 5 Sep 2013 20:34:58 GMT (envelope-from joerg@svn.freebsd.org) Received: (from joerg@localhost) by svn.freebsd.org (8.14.7/8.14.5/Submit) id r85KYwfN090551; Thu, 5 Sep 2013 20:34:58 GMT (envelope-from joerg@svn.freebsd.org) Message-Id: <201309052034.r85KYwfN090551@svn.freebsd.org> From: Joerg Wunsch Date: Thu, 5 Sep 2013 20:34:58 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-8@freebsd.org Subject: svn commit: r255264 - stable/8/sys/dev/fdc X-SVN-Group: stable-8 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-stable-8@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for only the 8-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 05 Sep 2013 20:34:58 -0000 Author: joerg Date: Thu Sep 5 20:34:58 2013 New Revision: 255264 URL: http://svnweb.freebsd.org/changeset/base/255264 Log: Merged r254809 and 254937 from head: . Fix "2step" feature (i.e. 360 KiB media in 1200 KiB drives) . Fix FDOPT_NOERROR option Modified: stable/8/sys/dev/fdc/fdc.c Directory Properties: stable/8/sys/ (props changed) Modified: stable/8/sys/dev/fdc/fdc.c ============================================================================== --- stable/8/sys/dev/fdc/fdc.c Thu Sep 5 20:18:59 2013 (r255263) +++ stable/8/sys/dev/fdc/fdc.c Thu Sep 5 20:34:58 2013 (r255264) @@ -528,7 +528,8 @@ fdc_reset(struct fdc_data *fdc) if (fdc_cmd(fdc, 4, I8207X_CONFIG, 0, - 0x40 | /* Enable Implied Seek */ + /* 0x40 | */ /* Enable Implied Seek - + * breaks 2step! */ 0x10 | /* Polling disabled */ (fifo_threshold - 1), /* Fifo threshold */ 0x00, /* Precomp track */ @@ -760,10 +761,13 @@ fdc_worker(struct fdc_data *fdc) int i, nsect; int st0, st3, cyl, mfm, steptrac, cylinder, descyl, sec; int head; + int override_error; static int need_recal; struct fdc_readid *idp; struct fd_formb *finfo; + override_error = 0; + /* Have we exhausted our retries ? */ bp = fdc->bp; fd = fdc->fd; @@ -924,14 +928,8 @@ fdc_worker(struct fdc_data *fdc) /* * SEEK to where we want to be - * - * Enhanced controllers do implied seeks for read&write as long as - * we do not need multiple steps per track. */ - if (cylinder != fd->track && ( - fdc->fdct != FDC_ENHANCED || - descyl != cylinder || - (bp->bio_cmd & (BIO_RDID|BIO_FMT)))) { + if (cylinder != fd->track) { retry_line = __LINE__; if (fdc_cmd(fdc, 3, NE7CMD_SEEK, fd->fdsu, descyl, 0)) return (1); @@ -1101,7 +1099,10 @@ fdc_worker(struct fdc_data *fdc) fdc->status[3], fdc->status[4], fdc->status[5]); } retry_line = __LINE__; - return (1); + if (fd->options & FDOPT_NOERROR) + override_error = 1; + else + return (1); } /* All OK */ switch(bp->bio_cmd) { @@ -1122,10 +1123,16 @@ fdc_worker(struct fdc_data *fdc) bp->bio_resid -= fd->fd_iosize; bp->bio_completed += fd->fd_iosize; fd->fd_ioptr += fd->fd_iosize; - /* Since we managed to get something done, reset the retry */ - fdc->retry = 0; - if (bp->bio_resid > 0) - return (0); + if (override_error) { + if ((debugflags & 4)) + printf("FDOPT_NOERROR: returning bad data\n"); + } else { + /* Since we managed to get something done, + * reset the retry */ + fdc->retry = 0; + if (bp->bio_resid > 0) + return (0); + } break; case BIO_FMT: break; @@ -1417,6 +1424,7 @@ fd_access(struct g_provider *pp, int r, ae = e + pp->ace; if (ar == 0 && aw == 0 && ae == 0) { + fd->options &= ~(FDOPT_NORETRY | FDOPT_NOERRLOG | FDOPT_NOERROR); device_unbusy(fd->dev); return (0); } From owner-svn-src-stable-8@FreeBSD.ORG Sat Sep 7 06:41:23 2013 Return-Path: Delivered-To: svn-src-stable-8@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTP id 4B144A4E; Sat, 7 Sep 2013 06:41:23 +0000 (UTC) (envelope-from hselasky@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mx1.freebsd.org (Postfix) with ESMTPS id 375592E52; Sat, 7 Sep 2013 06:41:23 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.7/8.14.7) with ESMTP id r876fNcf035941; Sat, 7 Sep 2013 06:41:23 GMT (envelope-from hselasky@svn.freebsd.org) Received: (from hselasky@localhost) by svn.freebsd.org (8.14.7/8.14.5/Submit) id r876fMFp035939; Sat, 7 Sep 2013 06:41:22 GMT (envelope-from hselasky@svn.freebsd.org) Message-Id: <201309070641.r876fMFp035939@svn.freebsd.org> From: Hans Petter Selasky Date: Sat, 7 Sep 2013 06:41:22 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-8@freebsd.org Subject: svn commit: r255346 - in stable/8/sys: dev/usb netgraph/bluetooth/drivers/ubt X-SVN-Group: stable-8 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-stable-8@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for only the 8-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 07 Sep 2013 06:41:23 -0000 Author: hselasky Date: Sat Sep 7 06:41:22 2013 New Revision: 255346 URL: http://svnweb.freebsd.org/changeset/base/255346 Log: MFC r255090 and r255128: Add more USB IDs. PR: kern/181728 Modified: stable/8/sys/dev/usb/usbdevs stable/8/sys/netgraph/bluetooth/drivers/ubt/ng_ubt.c Directory Properties: stable/8/sys/ (props changed) stable/8/sys/dev/ (props changed) stable/8/sys/dev/usb/ (props changed) stable/8/sys/netgraph/ (props changed) Modified: stable/8/sys/dev/usb/usbdevs ============================================================================== --- stable/8/sys/dev/usb/usbdevs Sat Sep 7 06:38:34 2013 (r255345) +++ stable/8/sys/dev/usb/usbdevs Sat Sep 7 06:41:22 2013 (r255346) @@ -514,11 +514,13 @@ vendor USR 0x0baf U.S. Robotics vendor AMBIT 0x0bb2 Ambit Microsystems vendor HTC 0x0bb4 HTC vendor REALTEK 0x0bda Realtek +vendor ERICSSON2 0x0bdb Ericsson vendor MEI 0x0bed MEI vendor ADDONICS2 0x0bf6 Addonics Technology vendor FSC 0x0bf8 Fujitsu Siemens Computers vendor AGATE 0x0c08 Agate Technologies vendor DMI 0x0c0b DMI +vendor CANYON 0x0c10 Canyon vendor ICOM 0x0c26 Icom Inc. vendor GNOTOMETRICS 0x0c33 GN Otometrics vendor CHICONY2 0x0c45 Chicony Modified: stable/8/sys/netgraph/bluetooth/drivers/ubt/ng_ubt.c ============================================================================== --- stable/8/sys/netgraph/bluetooth/drivers/ubt/ng_ubt.c Sat Sep 7 06:38:34 2013 (r255345) +++ stable/8/sys/netgraph/bluetooth/drivers/ubt/ng_ubt.c Sat Sep 7 06:41:22 2013 (r255346) @@ -404,6 +404,67 @@ static const STRUCT_USB_HOST_ID ubt_devs USB_IFACE_CLASS(UICLASS_VENDOR), USB_IFACE_SUBCLASS(UDSUBCLASS_RF), USB_IFACE_PROTOCOL(UDPROTO_BLUETOOTH) }, + + /* Apple-specific (Broadcom) devices */ + { USB_VENDOR(USB_VENDOR_APPLE), + USB_IFACE_CLASS(UICLASS_VENDOR), + USB_IFACE_SUBCLASS(UDSUBCLASS_RF), + USB_IFACE_PROTOCOL(UDPROTO_BLUETOOTH) }, + + /* Foxconn - Hon Hai */ + { USB_VENDOR(USB_VENDOR_FOXCONN), + USB_IFACE_CLASS(UICLASS_VENDOR), + USB_IFACE_SUBCLASS(UDSUBCLASS_RF), + USB_IFACE_PROTOCOL(UDPROTO_BLUETOOTH) }, + + /* MediaTek MT76x0E */ + { USB_VPI(USB_VENDOR_MEDIATEK, 0x763f, 0) }, + + /* Broadcom SoftSailing reporting vendor specific */ + { USB_VPI(USB_VENDOR_BROADCOM, 0x21e1, 0) }, + + /* Apple MacBookPro 7,1 */ + { USB_VPI(USB_VENDOR_APPLE, 0x8213, 0) }, + + /* Apple iMac11,1 */ + { USB_VPI(USB_VENDOR_APPLE, 0x8215, 0) }, + + /* Apple MacBookPro6,2 */ + { USB_VPI(USB_VENDOR_APPLE, 0x8218, 0) }, + + /* Apple MacBookAir3,1, MacBookAir3,2 */ + { USB_VPI(USB_VENDOR_APPLE, 0x821b, 0) }, + + /* Apple MacBookAir4,1 */ + { USB_VPI(USB_VENDOR_APPLE, 0x821f, 0) }, + + /* MacBookAir6,1 */ + { USB_VPI(USB_VENDOR_APPLE, 0x828f, 0) }, + + /* Apple MacBookPro8,2 */ + { USB_VPI(USB_VENDOR_APPLE, 0x821a, 0) }, + + /* Apple MacMini5,1 */ + { USB_VPI(USB_VENDOR_APPLE, 0x8281, 0) }, + + /* Bluetooth Ultraport Module from IBM */ + { USB_VPI(USB_VENDOR_TDK, 0x030a, 0) }, + + /* ALPS Modules with non-standard ID */ + { USB_VPI(USB_VENDOR_ALPS, 0x3001, 0) }, + { USB_VPI(USB_VENDOR_ALPS, 0x3002, 0) }, + + { USB_VPI(USB_VENDOR_ERICSSON2, 0x1002, 0) }, + + /* Canyon CN-BTU1 with HID interfaces */ + { USB_VPI(USB_VENDOR_CANYON, 0x0000, 0) }, + + /* Broadcom BCM20702A0 */ + { USB_VPI(USB_VENDOR_ASUS, 0x17b5, 0) }, + { USB_VPI(USB_VENDOR_ASUS, 0x17cb, 0) }, + { USB_VPI(USB_VENDOR_LITEON, 0x2003, 0) }, + { USB_VPI(USB_VENDOR_FOXCONN, 0xe042, 0) }, + { USB_VPI(USB_VENDOR_DELL, 0x8197, 0) }, }; /*