Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 9 Mar 2009 13:27:33 +0000 (UTC)
From:      Warner Losh <imp@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org
Subject:   svn commit: r189578 - head/sys/dev/agp
Message-ID:  <200903091327.n29DRXgF027620@svn.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: imp
Date: Mon Mar  9 13:27:33 2009
New Revision: 189578
URL: http://svn.freebsd.org/changeset/base/189578

Log:
  Fix prototypes to be consistent.

Modified:
  head/sys/dev/agp/agp.c
  head/sys/dev/agp/agp_amd64.c
  head/sys/dev/agp/agp_i810.c
  head/sys/dev/agp/agp_intel.c
  head/sys/dev/agp/agp_via.c
  head/sys/dev/agp/agppriv.h

Modified: head/sys/dev/agp/agp.c
==============================================================================
--- head/sys/dev/agp/agp.c	Mon Mar  9 13:26:55 2009	(r189577)
+++ head/sys/dev/agp/agp.c	Mon Mar  9 13:27:33 2009	(r189578)
@@ -295,7 +295,7 @@ agp_generic_detach(device_t dev)
  * Default AGP aperture size detection which simply returns the size of
  * the aperture's PCI resource.
  */
-int
+u_int32_t
 agp_generic_get_aperture(device_t dev)
 {
 	struct agp_softc *sc = device_get_softc(dev);

Modified: head/sys/dev/agp/agp_amd64.c
==============================================================================
--- head/sys/dev/agp/agp_amd64.c	Mon Mar  9 13:26:55 2009	(r189577)
+++ head/sys/dev/agp/agp_amd64.c	Mon Mar  9 13:27:33 2009	(r189578)
@@ -333,7 +333,7 @@ agp_amd64_set_aperture(device_t dev, uin
 }
 
 static int
-agp_amd64_bind_page(device_t dev, int offset, vm_offset_t physical)
+agp_amd64_bind_page(device_t dev, vm_offset_t offset, vm_offset_t physical)
 {
 	struct agp_amd64_softc *sc = device_get_softc(dev);
 
@@ -347,7 +347,7 @@ agp_amd64_bind_page(device_t dev, int of
 }
 
 static int
-agp_amd64_unbind_page(device_t dev, int offset)
+agp_amd64_unbind_page(device_t dev, vm_offset_t offset)
 {
 	struct agp_amd64_softc *sc = device_get_softc(dev);
 

Modified: head/sys/dev/agp/agp_i810.c
==============================================================================
--- head/sys/dev/agp/agp_i810.c	Mon Mar  9 13:26:55 2009	(r189577)
+++ head/sys/dev/agp/agp_i810.c	Mon Mar  9 13:27:33 2009	(r189578)
@@ -836,12 +836,12 @@ agp_i810_write_gtt_entry(device_t dev, i
 }
 
 static int
-agp_i810_bind_page(device_t dev, int offset, vm_offset_t physical)
+agp_i810_bind_page(device_t dev, vm_offset_t offset, vm_offset_t physical)
 {
 	struct agp_i810_softc *sc = device_get_softc(dev);
 
 	if (offset < 0 || offset >= (sc->gatt->ag_entries << AGP_PAGE_SHIFT)) {
-		device_printf(dev, "failed: offset is 0x%08x, shift is %d, entries is %d\n", offset, AGP_PAGE_SHIFT, sc->gatt->ag_entries);
+		device_printf(dev, "failed: offset is 0x%08jx, shift is %d, entries is %d\n", (intmax_t)offset, AGP_PAGE_SHIFT, sc->gatt->ag_entries);
 		return EINVAL;
 	}
 
@@ -858,7 +858,7 @@ agp_i810_bind_page(device_t dev, int off
 }
 
 static int
-agp_i810_unbind_page(device_t dev, int offset)
+agp_i810_unbind_page(device_t dev, vm_offset_t offset)
 {
 	struct agp_i810_softc *sc = device_get_softc(dev);
 

Modified: head/sys/dev/agp/agp_intel.c
==============================================================================
--- head/sys/dev/agp/agp_intel.c	Mon Mar  9 13:26:55 2009	(r189577)
+++ head/sys/dev/agp/agp_intel.c	Mon Mar  9 13:27:33 2009	(r189578)
@@ -365,7 +365,7 @@ agp_intel_set_aperture(device_t dev, u_i
 }
 
 static int
-agp_intel_bind_page(device_t dev, int offset, vm_offset_t physical)
+agp_intel_bind_page(device_t dev, vm_offset_t offset, vm_offset_t physical)
 {
 	struct agp_intel_softc *sc;
 
@@ -379,7 +379,7 @@ agp_intel_bind_page(device_t dev, int of
 }
 
 static int
-agp_intel_unbind_page(device_t dev, int offset)
+agp_intel_unbind_page(device_t dev, vm_offset_t offset)
 {
 	struct agp_intel_softc *sc;
 

Modified: head/sys/dev/agp/agp_via.c
==============================================================================
--- head/sys/dev/agp/agp_via.c	Mon Mar  9 13:26:55 2009	(r189577)
+++ head/sys/dev/agp/agp_via.c	Mon Mar  9 13:27:33 2009	(r189578)
@@ -358,7 +358,7 @@ agp_via_set_aperture(device_t dev, u_int
 }
 
 static int
-agp_via_bind_page(device_t dev, int offset, vm_offset_t physical)
+agp_via_bind_page(device_t dev, vm_offset_t offset, vm_offset_t physical)
 {
 	struct agp_via_softc *sc = device_get_softc(dev);
 
@@ -370,7 +370,7 @@ agp_via_bind_page(device_t dev, int offs
 }
 
 static int
-agp_via_unbind_page(device_t dev, int offset)
+agp_via_unbind_page(device_t dev, vm_offset_t offset)
 {
 	struct agp_via_softc *sc = device_get_softc(dev);
 

Modified: head/sys/dev/agp/agppriv.h
==============================================================================
--- head/sys/dev/agp/agppriv.h	Mon Mar  9 13:26:55 2009	(r189577)
+++ head/sys/dev/agp/agppriv.h	Mon Mar  9 13:27:33 2009	(r189578)
@@ -92,7 +92,7 @@ void		        agp_free_gatt(struct agp_g
 void			agp_free_res(device_t dev);
 int			agp_generic_attach(device_t dev);
 int			agp_generic_detach(device_t dev);
-int			agp_generic_get_aperture(device_t dev);
+u_int32_t		agp_generic_get_aperture(device_t dev);
 int			agp_generic_set_aperture(device_t dev,
 						 u_int32_t aperture);
 int			agp_generic_enable(device_t dev, u_int32_t mode);



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