The NetBSD Project

CVS log for src/sys/dev/video.c

[BACK] Up to [cvs.NetBSD.org] / src / sys / dev

Request diff between arbitrary revisions


Default branch: MAIN
Current tag: uebayasi-xip-base1


Revision 1.23 / (download) - annotate - [select for diffs], Sun Dec 6 22:42:48 2009 UTC (14 years, 4 months ago) by dyoung
Branch: MAIN
CVS Tags: yamt-nfs-mp-base9, yamt-nfs-mp-base11, yamt-nfs-mp-base10, uebayasi-xip-base4, uebayasi-xip-base3, uebayasi-xip-base2, uebayasi-xip-base1, uebayasi-xip-base, uebayasi-xip, matt-premerge-20091211
Branch point for: rmind-uvmplock
Changes since 1.22: +6 -9 lines
Diff to previous 1.22 (colored)

Simplify these device-activation hooks using the following semantic
patch.

XXX sc_dying must die.

@@
type device_t;

identifier act, midi_softc, midiactivate, sc, self;
@@

int
midiactivate(device_t self, enum devact act)
{
(
	struct midi_softc *sc = device_private(self);
|
-	struct midi_softc *sc;
+	struct midi_softc *sc = device_private(self);
...
-	sc = device_private(self);
)
...
	switch (act) {
-	case DVACT_ACTIVATE:
-		return (EOPNOTSUPP);
-
	case DVACT_DEACTIVATE:
(
	sc->dying
|
	sc->sc_dying
)
		=
(
	1
|
	true
)
		;
-		break;
+		return 0;
+	default:
+		return EOPNOTSUPP;
	}
-	return (0);
}

This form allows you to request diff's between any two revisions of a file. You may select a symbolic revision name using the selection box or you may type in a numeric name using the type-in text box.




CVSweb <webmaster@jp.NetBSD.org>