Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 11 Apr 2006 02:27:43 GMT
From:      Marcel Moolenaar <marcel@FreeBSD.org>
To:        Perforce Change Reviews <perforce@freebsd.org>
Subject:   PERFORCE change 94967 for review
Message-ID:  <200604110227.k3B2Rh0o098973@repoman.freebsd.org>

next in thread | raw e-mail | index | archive | help
http://perforce.freebsd.org/chv.cgi?CH=94967

Change 94967 by marcel@marcel_nfs on 2006/04/11 02:27:30

	Revert the addition of a register shift and revert the exposure
	of the port number. Both are not needed anymore.

Affected files ...

.. //depot/projects/uart/dev/puc/puc.c#19 edit
.. //depot/projects/uart/dev/puc/pucvar.h#14 edit
.. //depot/projects/uart/dev/uart/uart_bus_puc.c#13 edit

Differences ...

==== //depot/projects/uart/dev/puc/puc.c#19 (text+ko) ====

@@ -102,8 +102,6 @@
 
 struct puc_device {
 	struct resource_list resources;
-	int	port;
-	int	regshft;
 	u_int	serialfreq;
 };
 
@@ -314,9 +312,7 @@
 			rman_set_bushandle(rle->res, bh);
 		}
 
-		pdev->port = i + 1;
 		pdev->serialfreq = sc->sc_desc.ports[i].serialfreq;
-		pdev->regshft = sc->sc_desc.ports[i].regshft;
 
 		childunit = puc_find_free_unit(typestr);
 		sc->sc_ports[i].dev = device_add_child(dev, typestr,
@@ -576,12 +572,6 @@
 	case PUC_IVAR_FREQ:
 		*result = pdev->serialfreq;
 		break;
-	case PUC_IVAR_PORT:
-		*result = pdev->port;
-		break;
-	case PUC_IVAR_REGSHFT:
-		*result = pdev->regshft;
-		break;
 	default:
 		return (ENOENT);
 	}

==== //depot/projects/uart/dev/puc/pucvar.h#14 (text+ko) ====

@@ -78,7 +78,6 @@
 		int	offset;
 		u_int	serialfreq;
 		u_int	flags;
-		int	regshft;
 	} ports[PUC_MAX_PORTS];
 	uint32_t	ilr_type;
 	uint32_t	ilr_offset[2];
@@ -104,9 +103,7 @@
 #define PUC_MAX_BAR		6
 
 enum puc_device_ivars {
-	PUC_IVAR_FREQ,
-	PUC_IVAR_REGSHFT,
-	PUC_IVAR_PORT
+	PUC_IVAR_FREQ
 };
 
 #ifdef PUC_ENTRAILS

==== //depot/projects/uart/dev/uart/uart_bus_puc.c#13 (text+ko) ====

@@ -70,7 +70,7 @@
 {
 	device_t parent;
 	struct uart_softc *sc;
-	uintptr_t rclk, regshft;
+	uintptr_t rclk;
 
 	parent = device_get_parent(dev);
 	sc = device_get_softc(dev);
@@ -79,9 +79,7 @@
 
 	if (BUS_READ_IVAR(parent, dev, PUC_IVAR_FREQ, &rclk))
 		rclk = 0;
-	if (BUS_READ_IVAR(parent, dev, PUC_IVAR_REGSHFT, &regshft))
-		regshft = 0;
-	return (uart_bus_probe(dev, regshft, rclk, 0, 0));
+	return (uart_bus_probe(dev, 0, rclk, 0, 0));
 }
 
 DRIVER_MODULE(uart, puc, uart_puc_driver, uart_devclass, 0, 0);



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200604110227.k3B2Rh0o098973>