From 4f9a8d23e4d70d4c7700c83d907535267ebcc1d3 Mon Sep 17 00:00:00 2001 From: "Kirill Lipatov (Leency)" Date: Tue, 30 Apr 2019 11:05:08 +0000 Subject: [PATCH] 1. loaddrv: show load drv result, show hint on error 2. debug.inc no need to use macros.inc for only one mcall 3. small fix in sysfuncs.txt 4. remove duplicated vendors in pcidev app git-svn-id: svn://kolibrios.org@7644 a494cfbc-eb01-0410-851d-a64ba20cac60 --- kernel/trunk/docs/sysfuncr.txt | 2 +- kernel/trunk/docs/sysfuncs.txt | 2 +- programs/debug.inc | 4 +++- programs/system/loaddrv/build.bat | 2 ++ programs/system/loaddrv/loaddrv.asm | 19 ++++++++++++++++--- programs/system/pcidev/trunk/vendors.add | 4 ---- 6 files changed, 23 insertions(+), 10 deletions(-) create mode 100644 programs/system/loaddrv/build.bat diff --git a/kernel/trunk/docs/sysfuncr.txt b/kernel/trunk/docs/sysfuncr.txt index 4206e79211..eb5026e295 100644 --- a/kernel/trunk/docs/sysfuncr.txt +++ b/kernel/trunk/docs/sysfuncr.txt @@ -3379,7 +3379,7 @@ Architecture Software Developer's Manual, Volume 3, Appendix B); * Имя драйвера чувствительно к регистру символов. Максимальная длина имени - 16 символов, включая завершающий нулевой символ, остальные символы игнорируются. - * Драйвер с именем ABC загружается из файла /rd/1/drivers/ABC.obj. + * Драйвер с именем ABC загружается из файла /rd/1/drivers/ABC.sys. ---------------------- Константы для регистров: ---------------------- eax - SF_SYS_MISC (68) diff --git a/kernel/trunk/docs/sysfuncs.txt b/kernel/trunk/docs/sysfuncs.txt index 86dcab26e6..8f24c87202 100644 --- a/kernel/trunk/docs/sysfuncs.txt +++ b/kernel/trunk/docs/sysfuncs.txt @@ -3348,7 +3348,7 @@ Remarks: * Driver name is case-sensitive. Maximum length of the name is 16 characters, including terminating null character, the rest is ignored. - * Driver ABC is loaded from file /rd/1/drivers/ABC.obj. + * Driver ABC is loaded from file /rd/1/drivers/ABC.sys. ---------------------- Constants for registers: ---------------------- eax - SF_SYS_MISC (68) diff --git a/programs/debug.inc b/programs/debug.inc index f58479019a..41cef9773f 100644 --- a/programs/debug.inc +++ b/programs/debug.inc @@ -121,7 +121,9 @@ debug_outhex: and cl, 0x0f mov cl, [__hexdigits + ecx] pushad - mcall 63, 1 + mov eax, 63 + mov ebx, 1 + int 0x40 popad dec edx jnz .new_char diff --git a/programs/system/loaddrv/build.bat b/programs/system/loaddrv/build.bat new file mode 100644 index 0000000000..4832e3b7ca --- /dev/null +++ b/programs/system/loaddrv/build.bat @@ -0,0 +1,2 @@ +@fasm loaddrv.asm loaddrv +@pause \ No newline at end of file diff --git a/programs/system/loaddrv/loaddrv.asm b/programs/system/loaddrv/loaddrv.asm index b50e2af855..90d31caf2b 100644 --- a/programs/system/loaddrv/loaddrv.asm +++ b/programs/system/loaddrv/loaddrv.asm @@ -14,18 +14,31 @@ use32 dd i_end dd mem dd mem - dd path, 0 + dd driver_name, 0 ; NAME W/O EXT, NOT PATH. SEE f68.16 +include '../../debug.inc' + start: mov eax, 68 mov ebx, 16 - mov ecx, path + mov ecx, driver_name int 0x40 + cmp eax, 0 + jne ok +nok: + print 'LoadDrv: Error loading driver' + print 'Driver must be in /sys/drivers/ folder.' + print 'Its name must be w/o extension and it is case-sensitive' mov eax, -1 int 0x40 +ok: + print 'LoadDrv: Driver loaded well' + mov eax, -1 + int 0x40 + i_end: - path rb 1024 + driver_name rb 1024 mem: \ No newline at end of file diff --git a/programs/system/pcidev/trunk/vendors.add b/programs/system/pcidev/trunk/vendors.add index 41ec78cf3f..25afd09c29 100644 --- a/programs/system/pcidev/trunk/vendors.add +++ b/programs/system/pcidev/trunk/vendors.add @@ -54,8 +54,6 @@ VendorID 0x1085, 'Tulip Computers International BV' VendorID 0x1087, 'Cache Computer' VendorID 0x108A, 'SBS Operations' VendorID 0x108D, 'OLICOM' -VendorID 0x10C8, 'NEOMAGIC CORPORATION' -VendorID 0x11AD, 'LITE-ON COMMUNICATIONS INC' VendorID 0x11AE, 'SCITEX CORPORATION' VendorID 0x11AF, 'AVID TECHNOLOGY INC' VendorID 0x11B0, 'V3 SEMICONDUCTOR INC./Quicklogic Corp' @@ -194,7 +192,6 @@ VendorID 0x120E, 'Cyclades Corporation' VendorID 0x120F, 'ESSENTIAL COMMUNICATIONS' VendorID 0x1214, 'PERFORMANCE TECHNOLOGIES.' VendorID 0x1216, 'PURUP-EskoFot A/S' -VendorID 0x1217, 'O2MICRO.' VendorID 0x121A, '3DFX INTERACTIVE' VendorID 0x121B, 'VIRATA LTD' VendorID 0x1220, 'Ariel Corporation' @@ -551,7 +548,6 @@ VendorID 0x14DF, 'BASIS COMMUNICATIONS CORP' VendorID 0x14E1, 'INVERTEX' VendorID 0x14E2, 'INFOLIBRIA' VendorID 0x14E3, 'AMTELCO' -VendorID 0x14E4, 'BROADCOM CORPORATION' VendorID 0x14E5, 'PIXELFUSION LTD' VendorID 0x14E6, 'SHINING TECHNOLOGY INC' VendorID 0x14E7, '3CX'