diff --git a/DEVELOPERS-HINTS b/DEVELOPERS-HINTS
index b4e64557f6be1422e7448c7cc35f732c22c88e5e..f8967312416722ad1ac23a9ddc84c862b7fb84e9 100644
--- a/DEVELOPERS-HINTS
+++ b/DEVELOPERS-HINTS
@@ -181,7 +181,6 @@ Note: these directories will ultimately get moved into their
 respective dlls.
 
 	files/			- KERNEL file I/O
-	memory/			- KERNEL memory management
 	misc/			- KERNEL shell, registry, winsock, etc.
 	msdos/			- KERNEL DOS support
 
diff --git a/configure b/configure
index 2032548b0bf129c61ff48a0fb487fa2b74221d19..990ac6d5c30dc337c7f3573227eaac2807589033 100755
--- a/configure
+++ b/configure
@@ -13292,7 +13292,7 @@ then
 cat >>confdefs.h <<_ACEOF
 #define SONAME_LIBFONTCONFIG "$ac_cv_lib_soname_fontconfig"
 _ACEOF
-fi;
+fi
 
 echo "$as_me:$LINENO: checking for -lssl soname" >&5
 echo $ECHO_N "checking for -lssl soname... $ECHO_C" >&6
@@ -17096,8 +17096,6 @@ esac
 
           ac_config_commands="$ac_config_commands include/wine"
 
-          ac_config_commands="$ac_config_commands memory"
-
           ac_config_commands="$ac_config_commands misc"
 
           ac_config_commands="$ac_config_commands msdos"
@@ -17871,7 +17869,6 @@ do
   "graphics" ) CONFIG_COMMANDS="$CONFIG_COMMANDS graphics" ;;
   "graphics/x11drv" ) CONFIG_COMMANDS="$CONFIG_COMMANDS graphics/x11drv" ;;
   "include/wine" ) CONFIG_COMMANDS="$CONFIG_COMMANDS include/wine" ;;
-  "memory" ) CONFIG_COMMANDS="$CONFIG_COMMANDS memory" ;;
   "misc" ) CONFIG_COMMANDS="$CONFIG_COMMANDS misc" ;;
   "msdos" ) CONFIG_COMMANDS="$CONFIG_COMMANDS msdos" ;;
   "objects" ) CONFIG_COMMANDS="$CONFIG_COMMANDS objects" ;;
@@ -18599,8 +18596,6 @@ echo "$as_me: creating graphics" >&6;} && mkdir "graphics") ;;
 echo "$as_me: creating graphics/x11drv" >&6;} && mkdir "graphics/x11drv") ;;
     include/wine ) test -d "include/wine" || ({ echo "$as_me:$LINENO: creating include/wine" >&5
 echo "$as_me: creating include/wine" >&6;} && mkdir "include/wine") ;;
-    memory ) test -d "memory" || ({ echo "$as_me:$LINENO: creating memory" >&5
-echo "$as_me: creating memory" >&6;} && mkdir "memory") ;;
     misc ) test -d "misc" || ({ echo "$as_me:$LINENO: creating misc" >&5
 echo "$as_me: creating misc" >&6;} && mkdir "misc") ;;
     msdos ) test -d "msdos" || ({ echo "$as_me:$LINENO: creating msdos" >&5
diff --git a/configure.ac b/configure.ac
index 3be5d362ddf2bea6aa89f774571b2fa205c642d1..17a53ff5f10db24687b4a9218ddfbe20593b7a6b 100644
--- a/configure.ac
+++ b/configure.ac
@@ -959,7 +959,7 @@ then
   WINE_GET_SONAME(GL,glXQueryExtension,[$X_LIBS $X_EXTRA_LIBS])
   WINE_GET_SONAME(cups,cupsGetDefault)
   WINE_GET_SONAME(jack,jack_client_new)
-  WINE_GET_SONAME(fontconfig, FcInit);
+  WINE_GET_SONAME(fontconfig,FcInit)
   WINE_GET_SONAME(ssl,SSL_library_init)
   WINE_GET_SONAME(crypto,BIO_new_socket)
   WINE_GET_SONAME(ncurses,waddch)
@@ -1415,7 +1415,6 @@ WINE_CONFIG_EXTRA_DIR(files)
 WINE_CONFIG_EXTRA_DIR(graphics)
 WINE_CONFIG_EXTRA_DIR(graphics/x11drv)
 WINE_CONFIG_EXTRA_DIR(include/wine)
-WINE_CONFIG_EXTRA_DIR(memory)
 WINE_CONFIG_EXTRA_DIR(misc)
 WINE_CONFIG_EXTRA_DIR(msdos)
 WINE_CONFIG_EXTRA_DIR(objects)
diff --git a/dlls/kernel/Makefile.in b/dlls/kernel/Makefile.in
index 34c9804e2adda8b0bc050a6e14f9b8aff3b49888..da3934ffd1acb4dd54e0190a7300b6110646d51f 100644
--- a/dlls/kernel/Makefile.in
+++ b/dlls/kernel/Makefile.in
@@ -23,9 +23,6 @@ C_SRCS = \
 	$(TOPOBJDIR)/files/drive.c \
 	$(TOPOBJDIR)/files/file.c \
 	$(TOPOBJDIR)/files/smb.c \
-	$(TOPOBJDIR)/memory/environ.c \
-	$(TOPOBJDIR)/memory/virtual.c \
-	$(TOPOBJDIR)/misc/cpu.c \
 	$(TOPOBJDIR)/misc/options.c \
 	$(TOPOBJDIR)/misc/registry.c \
 	$(TOPOBJDIR)/msdos/dpmi.c \
@@ -35,10 +32,12 @@ C_SRCS = \
 	comm.c \
 	computername.c \
 	console.c \
+	cpu.c \
 	debugger.c \
 	device.c \
 	dosmem.c \
 	editline.c \
+	environ.c \
 	except.c \
 	fiber.c \
 	file.c \
@@ -76,6 +75,7 @@ C_SRCS = \
 	toolhelp.c \
 	utthunk.c \
 	version.c \
+	virtual.c \
 	vxd.c \
 	win87em.c \
 	windebug.c \
@@ -99,7 +99,6 @@ EXTRA_OBJS   = $(ASM_SRCS:.s=.o)
 SUBDIRS      = tests
 EXTRASUBDIRS = \
 	$(TOPOBJDIR)/files \
-	$(TOPOBJDIR)/memory \
 	$(TOPOBJDIR)/misc \
 	$(TOPOBJDIR)/msdos \
 	messages \
diff --git a/misc/cpu.c b/dlls/kernel/cpu.c
similarity index 100%
rename from misc/cpu.c
rename to dlls/kernel/cpu.c
diff --git a/memory/environ.c b/dlls/kernel/environ.c
similarity index 100%
rename from memory/environ.c
rename to dlls/kernel/environ.c
diff --git a/memory/virtual.c b/dlls/kernel/virtual.c
similarity index 100%
rename from memory/virtual.c
rename to dlls/kernel/virtual.c
diff --git a/tools/winapi/msvcmaker b/tools/winapi/msvcmaker
index afc9fc03c6392f462498baf3fbe1a22514bb097a..657caada1fec85fb921fd7f9d50375b7f1e3b004 100755
--- a/tools/winapi/msvcmaker
+++ b/tools/winapi/msvcmaker
@@ -88,7 +88,7 @@ sub read_spec_file {
 }
 
 my @gdi32_dirs = qw(dlls/gdi/enhmfdrv dlls/gdi/mfdrv graphics objects);
-my @ntdll_dirs = qw(files memory misc msdos);
+my @ntdll_dirs = qw(files misc msdos);
 my @user32_dirs = qw(controls dlls/user/dde windows);
 
 push @makefile_in_files, "tools/winebuild/Makefile.in";
diff --git a/tools/winapi_check/modules.dat b/tools/winapi_check/modules.dat
index 96708cb41046268d68cf1d2219e76031d4520ebd..c90f415b908f1d3e3447cdc2fe3f89bae32462bf 100644
--- a/tools/winapi_check/modules.dat
+++ b/tools/winapi_check/modules.dat
@@ -1,7 +1,6 @@
 % dlls/advapi32/advapi32.spec
 
 dlls/advapi32
-memory
 misc
 
 % dlls/avicap32/avicap32.spec
@@ -199,7 +198,6 @@ dlls/iphlpapi
 
 dlls/kernel
 files
-memory
 misc
 msdos
 
@@ -207,7 +205,6 @@ msdos
 
 dlls/kernel
 files
-memory
 msdos
 misc
 
@@ -249,13 +246,11 @@ dlls/kernel
 
 % dlls/kernel/system.drv.spec
 
-memory
 misc
 
 % dlls/kernel/toolhelp.spec
 
 dlls/kernel
-memory
 
 % dlls/kernel/win87em.spec