summaryrefslogtreecommitdiffstats
path: root/winsup/cygwin/fhandler_mem.cc
Commit message (Collapse)AuthorAgeFilesLines
* Whitespace cleanup.Christopher Faylor2000-10-281-3/+3
| | | | | | * configure.in: Eliminate subdir stuff. * configure: Regenerate. * include/getopt.h (option): Make name field 'const'.
* * autoload.cc: New file keeping all autoload stuff.Corinna Vinschen2000-10-271-40/+0
| | | | | | | | * Makefile.in: Add autoload.o to dependencies. * dcrt0.cc: Move all autoload stuff to autoload.cc. * fhandler_mem.cc: Ditto. * net.cc: Ditto. * uinfo.cc: Ditto.
* * ntdll.h: New file.Corinna Vinschen2000-10-241-36/+1
| | | | | | | * fhandler_mem.cc: Move ntdll.dll specific definitions and declarations to ntdll.h. * sysconf.cc (sysconf): Add support for _SC_NPROCESSORS_CONF, _SC_NPROCESSORS_ONLN, _SC_PHYS_PAGES and _SC_AVPHYS_PAGES.
* * fhandler_mem.cc (fhandler_dev_mem::fhandler_dev_mem): Fix debug output.Corinna Vinschen2000-10-091-2/+2
|
* * fhandler_mem.cc: Eliminate unused include statements.Corinna Vinschen2000-10-091-3/+7
| | | | (fhandler_dev_mem::fhandler_dev_mem): Check for 9X/ME.
* * fhandler.h (fhandler_dev_mem): Erase member `init_phase' andCorinna Vinschen2000-10-091-33/+47
| | | | | | | | | | | | | | member function `init'. * fhandler_mem.cc: Add typedefs for NT internal data types `SYSTEM_INFORMATION_CLASS' and `SYSTEM_BASIC_INFORMATION'. Add prototype for `NtQuerySystemInformation' function. (fhandler_dev_mem::fhandler_dev_mem): Takes over initialization task from `init'. Use `NtQuerySystemInformation' function to evaluate the size of physical memory instead of interval search. (fhandler_dev_mem::init): Eliminated. (fhandler_dev_mem::open): Don't call `init'. (fhandler_dev_mem::read): Eliminate check for `init_phase'. (dummy_autoload): Add load statement for `NtQuerySystemInformation'.
* * fhandler.h (fhandler_dev_mem): Add methods mmap, munmap and msync.Corinna Vinschen2000-10-071-20/+139
| | | | | | | | | | | | | | | Add `unit' member. * fhandler_mem.cc (fhandler_dev_mem): Initialize `unit' as well. (init): Care for differences between /dev/mem, /dev/kmem (not implemented yet) and /dev/port. (open): Change debug message to reflect the device. (mmap): New function. (munmap): Ditto. (msync): Ditto. (fstat): Use unit when setting st_dev in stat structure. * mmap.cc (mmap): Handle MAP_ANONYMOUS flag. Change error handling slightly. * path.cc (get_device_number): Handle /dev/port.
* * fhandler.h (fhandler_dev_mem): Add method `init'. Add membersCorinna Vinschen2000-10-041-16/+124
| | | | | | | | | | | | | | `mem_size' and `init_phase'. * fhandler_mem.cc (init): New function to figure out the size of the physical memory. (open): Add checking for illegal flags. Change usage of access mode. (write): Add intended functionality. (read): Add parameter checking. Eliminate page size constant. Use getpagesize() instead. Don't touch errno and don't create debug output while init() is running. (lseek): Add bounds checking. Fix SEEK_END. (fstat): Eliminate page size constant. Use getpagesize() instead. (dup): Add intended functionality.
* * fhandler_mem.cc: Load ntdll functions via autoload method.Corinna Vinschen2000-10-021-82/+53
| | | | (load_ntdll_funcs): Eliminated.
* * fhandler_mem.cc (load_ntdll_funcs): Add missing __stdcall qualifiers.Corinna Vinschen2000-10-021-7/+9
|
* * Makefile.in: Add fhandler_mem.o to the dependencies.Corinna Vinschen2000-10-011-0/+260
* dtable.cc (dtable::build_fhandler): Add case for FH_MEM. * fhandler.h: Add FH_MEM device type. Add class fhandler_dev_mem. * fhandler_mem.cc: New file. Implementation of class fhandler_dev_mem. * path.cc: Add /dev/mem to windows_device_names. (get_device_number): Add FH_MEM type.