Wed Jul 24 02:44:48 2013 UTC ()
Ctassert that AGP_PAGE_SIZE == PAGE_SIZE in drm_agp_netbsd.h.

Linux assumes this.


(riastradh)
diff -r1.1.2.2 -r1.1.2.3 src/sys/external/bsd/drm2/include/drm/drm_agp_netbsd.h

cvs diff -r1.1.2.2 -r1.1.2.3 src/sys/external/bsd/drm2/include/drm/drm_agp_netbsd.h (expand / switch to unified diff)

--- src/sys/external/bsd/drm2/include/drm/drm_agp_netbsd.h 2013/07/24 01:59:52 1.1.2.2
+++ src/sys/external/bsd/drm2/include/drm/drm_agp_netbsd.h 2013/07/24 02:44:48 1.1.2.3
@@ -1,14 +1,14 @@ @@ -1,14 +1,14 @@
1/* $NetBSD: drm_agp_netbsd.h,v 1.1.2.2 2013/07/24 01:59:52 riastradh Exp $ */ 1/* $NetBSD: drm_agp_netbsd.h,v 1.1.2.3 2013/07/24 02:44:48 riastradh Exp $ */
2 2
3/*- 3/*-
4 * Copyright (c) 2013 The NetBSD Foundation, Inc. 4 * Copyright (c) 2013 The NetBSD Foundation, Inc.
5 * All rights reserved. 5 * All rights reserved.
6 * 6 *
7 * This code is derived from software contributed to The NetBSD Foundation 7 * This code is derived from software contributed to The NetBSD Foundation
8 * by Taylor R. Campbell. 8 * by Taylor R. Campbell.
9 * 9 *
10 * Redistribution and use in source and binary forms, with or without 10 * Redistribution and use in source and binary forms, with or without
11 * modification, are permitted provided that the following conditions 11 * modification, are permitted provided that the following conditions
12 * are met: 12 * are met:
13 * 1. Redistributions of source code must retain the above copyright 13 * 1. Redistributions of source code must retain the above copyright
14 * notice, this list of conditions and the following disclaimer. 14 * notice, this list of conditions and the following disclaimer.
@@ -38,26 +38,29 @@ @@ -38,26 +38,29 @@
38 * You have been warned! 38 * You have been warned!
39 */ 39 */
40 40
41#include <sys/agpio.h> 41#include <sys/agpio.h>
42 42
43#include <dev/pci/pcivar.h> /* XXX include order botch */ 43#include <dev/pci/pcivar.h> /* XXX include order botch */
44#include <dev/pci/agpvar.h> 44#include <dev/pci/agpvar.h>
45 45
46#include <linux/kernel.h> 46#include <linux/kernel.h>
47#include <linux/pci.h> 47#include <linux/pci.h>
48 48
49#define __OS_HAS_AGP 1 49#define __OS_HAS_AGP 1
50 50
 51__CTASSERT(PAGE_SIZE == AGP_PAGE_SIZE);
 52__CTASSERT(PAGE_SHIFT == AGP_PAGE_SHIFT);
 53
51typedef struct agp_memory DRM_AGP_MEM; 54typedef struct agp_memory DRM_AGP_MEM;
52typedef struct agp_info DRM_AGP_KERN; 55typedef struct agp_info DRM_AGP_KERN;
53 56
54struct agp_bridge_data { 57struct agp_bridge_data {
55 struct agp_softc abd_sc; /* XXX Abstraction violation! */ 58 struct agp_softc abd_sc; /* XXX Abstraction violation! */
56}; 59};
57 60
58/* 61/*
59 * We already have a struct agp_memory, but fortunately it looks like 62 * We already have a struct agp_memory, but fortunately it looks like
60 * it may accidentally work out. 63 * it may accidentally work out.
61 */ 64 */
62 65
63#if 0 66#if 0