svn commit: r294774 - head/usr.sbin/bhyve

Marcelo Araujo araujo at FreeBSD.org
Tue Jan 26 07:17:23 UTC 2016


Author: araujo
Date: Tue Jan 26 07:17:21 2016
New Revision: 294774
URL: https://svnweb.freebsd.org/changeset/base/294774

Log:
  Cleanup unused-but-set-variable spotted by gcc-4.9.
  
  Reviewed by:	neel
  Approved by:	rodrigc (mentor)
  Differential Revision:	https://reviews.freebsd.org/D5042

Modified:
  head/usr.sbin/bhyve/block_if.c
  head/usr.sbin/bhyve/pci_ahci.c

Modified: head/usr.sbin/bhyve/block_if.c
==============================================================================
--- head/usr.sbin/bhyve/block_if.c	Tue Jan 26 07:06:44 2016	(r294773)
+++ head/usr.sbin/bhyve/block_if.c	Tue Jan 26 07:17:21 2016	(r294774)
@@ -692,9 +692,7 @@ int
 blockif_close(struct blockif_ctxt *bc)
 {
 	void *jval;
-	int err, i;
-
-	err = 0;
+	int i;
 
 	assert(bc->bc_magic == BLOCKIF_SIG);
 

Modified: head/usr.sbin/bhyve/pci_ahci.c
==============================================================================
--- head/usr.sbin/bhyve/pci_ahci.c	Tue Jan 26 07:06:44 2016	(r294773)
+++ head/usr.sbin/bhyve/pci_ahci.c	Tue Jan 26 07:17:21 2016	(r294774)
@@ -1201,10 +1201,9 @@ atapi_read_toc(struct ahci_port *p, int 
 	{
 		int msf, size;
 		uint64_t sectors;
-		uint8_t start_track, *bp, buf[50];
+		uint8_t *bp, buf[50];
 
 		msf = (acmd[1] >> 1) & 1;
-		start_track = acmd[6];
 		bp = buf + 2;
 		*bp++ = 1;
 		*bp++ = 1;
@@ -1312,13 +1311,11 @@ atapi_read(struct ahci_port *p, int slot
 	struct ahci_cmd_hdr *hdr;
 	struct ahci_prdt_entry *prdt;
 	struct blockif_req *breq;
-	struct pci_ahci_softc *sc;
 	uint8_t *acmd;
 	uint64_t lba;
 	uint32_t len;
 	int err;
 
-	sc = p->pr_sc;
 	acmd = cfis + 0x40;
 	hdr = (struct ahci_cmd_hdr *)(p->cmd_lst + slot * AHCI_CL_SIZE);
 	prdt = (struct ahci_prdt_entry *)(cfis + 0x80);


More information about the svn-src-all mailing list