--- /n/sources/contrib2/stallion/src/sdmpt2.c Sat Aug 17 05:29:05 2013
+++ /sys/src/9/pc/sdmpt2.c Mon Sep 27 14:29:52 2021
@@ -7,9 +7,17 @@
#include "dat.h"
#include "fns.h"
#include "io.h"
+#include "../port/pci.h"
#include "../port/error.h"
#include "../port/sd.h"
+
+#define HOWMANY(x, y) (((x)+((y)-1))/(y))
+#define ROUNDUP(x, y) (HOWMANY((x), (y))*(y))
+
+#define L16GET(p) (((p)[1]<<8)|(p)[0])
+#define L32GET(p) (((u32int)L16GET((p)+2)<<16)|L16GET(p))
+#define L64GET(p) ((uvlong)L32GET((p)+4)<<32|L32GET(p))
extern SDifc sdmpt2ifc;
|