From 634c0e9aa41c553f65e9b039b3bcf1ecf9e283b4 Mon Sep 17 00:00:00 2001 From: "Artem Jerdev (art_zh)" Date: Mon, 14 Jan 2013 23:02:43 +0000 Subject: [PATCH] -A: minor updates git-svn-id: svn://kolibrios.org@3168 a494cfbc-eb01-0410-851d-a64ba20cac60 --- .../branches/Kolibri-A/trunk/boot/booteng.inc | 17 --- .../branches/Kolibri-A/trunk/core/sched.inc | 17 +-- .../Kolibri-A/trunk/gui/fonts/nsvf_00.asm | 10 +- .../Kolibri-A/trunk/gui/fonts/nsvf_02.asm | 118 ++++++++++-------- kernel/branches/Kolibri-A/trunk/init.inc | 4 +- kernel/branches/Kolibri-A/trunk/kernel.asm | 13 +- kernel/branches/Kolibri-A/trunk/kernel32.inc | 2 +- kernel/branches/Kolibri-A/trunk/memmap.inc | 4 +- .../branches/Kolibri-A/trunk/video/vesa20.inc | 45 ++++--- 9 files changed, 104 insertions(+), 126 deletions(-) delete mode 100644 kernel/branches/Kolibri-A/trunk/boot/booteng.inc diff --git a/kernel/branches/Kolibri-A/trunk/boot/booteng.inc b/kernel/branches/Kolibri-A/trunk/boot/booteng.inc deleted file mode 100644 index 536d4d4804..0000000000 --- a/kernel/branches/Kolibri-A/trunk/boot/booteng.inc +++ /dev/null @@ -1,17 +0,0 @@ -;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; -;; ;; -;; Copyright (C) KolibriOS team 2004-2011. All rights reserved. ;; -;; Distributed under terms of the GNU General Public License ;; -;; ;; -;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; - -;====================================================================== -; -; BOOT DATA -; -;====================================================================== - -$Revision$ - - -boot_dev db 0 ; 0=floppy, 1=hd diff --git a/kernel/branches/Kolibri-A/trunk/core/sched.inc b/kernel/branches/Kolibri-A/trunk/core/sched.inc index 00b4551bca..d1549e87a2 100644 --- a/kernel/branches/Kolibri-A/trunk/core/sched.inc +++ b/kernel/branches/Kolibri-A/trunk/core/sched.inc @@ -20,7 +20,7 @@ irq0: mov es, ax inc [timer_ticks] mov eax, [timer_ticks] - call playNote ; <<<--- Speaker driver +; call playNote ; <<<--- Speaker driver sub eax,[next_usage_update] cmp eax,100 jb .nocounter @@ -43,21 +43,6 @@ change_task: pushfd cli pushad -if 0 -; \begin{Mario79} ; <- must be refractoried, if used... - cmp [dma_task_switched], 1 - jne .find_next_task - mov [dma_task_switched], 0 - mov ebx, [dma_process] - cmp [CURRENT_TASK], ebx - je .return - mov edi, [dma_slot_ptr] - mov [CURRENT_TASK], ebx - mov [TASK_BASE], edi - jmp @f -.find_next_task: -; \end{Mario79} -end if call find_next_task jz .return ; the same task -> skip switch @@: mov byte[DONT_SWITCH], 1 diff --git a/kernel/branches/Kolibri-A/trunk/gui/fonts/nsvf_00.asm b/kernel/branches/Kolibri-A/trunk/gui/fonts/nsvf_00.asm index 48e939ee19..73736f5c9d 100644 --- a/kernel/branches/Kolibri-A/trunk/gui/fonts/nsvf_00.asm +++ b/kernel/branches/Kolibri-A/trunk/gui/fonts/nsvf_00.asm @@ -106,9 +106,9 @@ diff16 "sdsh_data.table0: ",0,$ dw (.ch0_88 -.chars)*16 + 2 ; #88 X dw (.ch0_89 -.chars)*16 + 2 ; #88 Y dw (.ch0_90 -.chars)*16 + 3 ; #90 Z - dw (.ch0_91 -.chars)*16 + 3 ; #91 [ + dw (.ch0_91 -.chars)*16 + 1 ; #91 [ dw (.ch0_92 -.chars)*16 + 1 ; #92 \ - dw (.ch0_93 -.chars)*16 + 3 ; #93 ] + dw (.ch0_93 -.chars)*16 + 1 ; #93 ] dw (.ch0_94 -.chars)*16 + 1 ; #94 ^ dw (.ch0_95 -.chars)*16 + 1 ; #95 _ dw (.ch0_96 -.chars)*16 + 1 ; #96 ` @@ -442,11 +442,9 @@ diff16 "sdsh_data.chars: ",0,$ .ch0_92: ; \ gptick 4, 6, 84 .ch0_91: ; [ - lntick 1, 3, 2, 5 + gptick 19, 4, 99 .ch0_93: ; ] - lntick 1, 2, 0, 3 - lntick 1, 8, 0, 3 - lntick 3, 3, 2, 5 + gptick 9, 0, 99 .ch0_65: ; A .ch0_128: ; lntick 0, 2, 2, 4 diff --git a/kernel/branches/Kolibri-A/trunk/gui/fonts/nsvf_02.asm b/kernel/branches/Kolibri-A/trunk/gui/fonts/nsvf_02.asm index 511c074bf7..e0d410f91d 100644 --- a/kernel/branches/Kolibri-A/trunk/gui/fonts/nsvf_02.asm +++ b/kernel/branches/Kolibri-A/trunk/gui/fonts/nsvf_02.asm @@ -18,9 +18,9 @@ align 4 db 0x1A ; 6 db 0x77 ; 7 db 0x49 ; 8 - db 0x00 ; 9 - db 0x00 ; 10 - db 0x00 ; 11 + db 0x62 ; 9 + db 0x2E ; 10 + db 0x1D ; 11 db 0x00 ; 12 db 0x00 ; 13 db 0x00 ; 14 @@ -48,36 +48,36 @@ align 4 diff16 "font02.table: ",0,$ times 33 dw 0 - char_entry .ch_33, 4, 4 ; #33 ! - char_entry .ch_34, 4, 2 ; #34 " + char_entry .ch_33, 2, 4 ; #33 ! + char_entry .ch_34, 2, 2 ; #34 " char_entry .ch_35, 0, 4 ; #35 # char_entry .ch_36, 0, 4 ; #36 $ char_entry .ch_37, 0, 3 ; #37 % dw (.ch_38 -.chars)*16 + 4 ; #38 & - char_entry .ch_39, 5, 1 ; #39 ' - dw (.ch_40 -.chars)*16 + 1 ; #40 ( - dw (.ch_41 -.chars)*16 + 1 ; #41 ) + char_entry .ch_39, 2, 1 ; #39 ' + char_entry .ch_40, 2, 1 ; #40 ( + char_entry .ch_41, 2, 1 ; #41 ) char_entry .ch_42, 1, 3 ; #42 * - dw (.ch_43 -.chars)*16 + 2 ; #43 + - dw (.ch_44 -.chars)*16 + 2 ; #44 , - dw (.ch_45 -.chars)*16 + 1 ; #45 - - dw (.ch_46 -.chars)*16 + 1 ; #46 . - char_entry .ch_47, 2, 1 ; #47 / - dw (.ch_48 -.chars)*16 + 2 ; #48 0 - dw (.ch_49 -.chars)*16 + 2 ; #49 1 - dw (.ch_50 -.chars)*16 + 3 ; #50 2 - dw (.ch_51 -.chars)*16 + 3 ; #51 3 + char_entry .ch_43, 1, 2 ; #43 + + char_entry .ch_44, 2, 2 ; #44 , + char_entry .ch_45, 1, 1 ; #45 - + char_entry .ch_46, 2, 2 ; #46 . + char_entry .ch_47, 1, 1 ; #47 / + char_entry .ch_48, 1, 2 ; #48 0 + char_entry .ch_49, 2, 3 ; #49 1 + char_entry .ch_50, 1, 3 ; #50 2 + char_entry .ch_51, 1, 2 ; #51 3 dw (.ch_52 -.chars)*16 + 3 ; #52 4 dw (.ch_53 -.chars)*16 + 2 ; #53 5 dw (.ch_54 -.chars)*16 + 2 ; #54 6 dw (.ch_55 -.chars)*16 + 2 ; #55 7 dw (.ch_56 -.chars)*16 + 2 ; #56 8 dw (.ch_57 -.chars)*16 + 2 ; #57 9 - dw (.ch_58 -.chars)*16 + 2 ; #58 : - dw (.ch_59 -.chars)*16 + 3 ; #59 ; + char_entry .ch_58, 4, 2 ; #58 : + char_entry .ch_59, 4, 4 ; #59 ; dw (.ch_60 -.chars)*16 + 1 ; #60 < - dw (.ch_61 -.chars)*16 + 2 ; #61 = + char_entry .ch_61, 0, 2 ; #61 = dw (.ch_62 -.chars)*16 + 1 ; #62 > dw (.ch_63 -.chars)*16 + 3 ; #63 ? dw (.ch_64 -.chars)*16 + 2 ; #64 @ @@ -89,6 +89,7 @@ diff16 "font02.table: ",0,$ dw (.ch_70 -.chars)*16 + 3 ; #70 F dw (.ch_71 -.chars)*16 + 2 ; #71 G dw (.ch_72 -.chars)*16 + 3 ; #72 H + char_entry .ch_73, 4, 3 ; #73 I dw (.ch_73 -.chars)*16 + 3 ; #73 I dw (.ch_74 -.chars)*16 + 2 ; #74 J dw (.ch_75 -.chars)*16 + 3 ; #75 K @@ -100,7 +101,6 @@ diff16 "font02.table: ",0,$ dw (.ch_81 -.chars)*16 + 3 ; #81 Q dw (.ch_82 -.chars)*16 + 3 ; #82 R char_entry .ch_83, 0, 2 ; #83 S - dw (.ch_83 -.chars)*16 + 3 ; #83 S dw (.ch_84 -.chars)*16 + 2 ; #84 T dw (.ch_85 -.chars)*16 + 3 ; #85 U dw (.ch_86 -.chars)*16 + 3 ; #86 V @@ -152,8 +152,8 @@ diff16 "font02.table: ",0,$ dw (.ch_131-.chars)*16 + 2 ; #131 dw (.ch_132-.chars)*16 + 6 ; #132 dw (.ch_133-.chars)*16 + 4 ; #133 E - dw (.ch_134-.chars)*16 + 3 ; #134 - dw (.ch_135-.chars)*16 + 3 ; #135 + dw (.ch_134-.chars)*16 + 3 ; #134 Zhe + char_entry .ch_135, 0, 4 ; #135 'Ze' dw (.ch_136-.chars)*16 + 3 ; #136 dw (.ch_137-.chars)*16 + 4 ; #137 dw (.ch_138-.chars)*16 + 3 ; #138 K @@ -267,6 +267,7 @@ diff16 "font02.chars: ",0,$ .chars: dw 0 .ch_33: ; ! +.ch_46: ; . lntick 3, 3, 0, 3 lntick 4, 2, 2, 3 lntick 4, 7, 2, 6 @@ -281,13 +282,17 @@ diff16 "font02.chars: ",0,$ lntick 0, 7, 0, 8 lntick 1,11, 0, 8 +.ch_135: ; 'Ze' + lntick 0,12, 0, 2 +.ch_51: ; 3 + gptick 11, 3, 106 .ch_36: ; $ - lntick 3, 2, 2, 14 - lntick 5, 2, 2, 14 -.ch_83: ; S +.ch_83: ; S gptick 8, 0, 125 gptick 1, 4, 118 lntick 0, 3, 3 + lntick 3, 2, 2, 14 + lntick 5, 2, 2, 14 .ch_37: ; % .ch_47: ; / @@ -300,52 +305,63 @@ diff16 "font02.chars: ",0,$ gptick 19, 4, 44 gptick 4, 0, 44 ritick 3, 3, 0 + .ch_40: ; ( - gptick 5, 3, 80 + gptick 9, 3, 121 .ch_41: ; ) - gptick 9, 7, 80 + gptick 10, 7, 121 + .ch_42: ; * gptick 7, 4, 71 gptick 6, 0, 71 - lntick 4, 5, 2, 8 .ch_43: ; + - lntick 2, 2, 2, 5 + lntick 4, 5, 2, 7 .ch_45: ; - + lntick 1, 8, 0, 7 .ch_61: ; = - lntick 0, 4, 0, 5 - lntick 0, 6, 0, 5 -.ch_58: ; : + lntick 1, 9, 0, 7 + lntick 1, 6, 0, 7 + .ch_59: ; ; - cstick 1, 7, 0, 0 -.ch_46: ; . + lntick 5, 9, 2, 2 +.ch_58: ; : + cstick 3,10, 0, 0 .ch_44: ; , - cstick 1, 3, 0, 0 - ritick 1, 1, 0 + cstick 3, 4, 0, 0 + gptick 3, 6, 48 + +.ch_48: ; 0 + gptick 7, 6, 122 + gptick 6, 2, 122 + .ch_55: ; 7 gptick 1, 2, 81 lntick 0, 8, 0, 4 .ch_64: ; @ cstick 2, 6, 0, 1 -.ch_48: ; 0 + .ch_79: ; O .ch_142: ; .ch_81: ; Q gptick 5, 4, 116 lntick 4, 3, 2, 5 lntick 3, 1, 0, 2 + .ch_49: ; 1 + lntick 2,10, 1, 2 +.ch_73: ; I + lntick 4, 4, 2, 11 + lntick 2, 3, 0, 5 + lntick 2,14, 0, 5 + .ch_124: ; | - lntick 2, 2, 2, 7 - ritick 1, 6, 0 + .ch_50: ; 2 - lntick 0, 2, 0, 5 - lntick 1, 3, 1, 3 -.ch_51: ; 3 - gptick 8, 1, 64 - gptick 10, 6, 65 -.ch_83: ; S - lntick 1, 5, 0, 3 - gptick 3, 2, 55 + gptick 11, 1, 106 + lntick 1, 5, 1, 5 + gptick 12, 6, 99 + + .ch_53: ; 5 gptick 10, 6, 65 gptick 13, 4, 104 @@ -407,10 +423,6 @@ diff16 "font02.chars: ",0,$ lntick 1, 5, 0, 3 lntick 0, 2, 2, 7 lntick 4, 2, 2, 7 -.ch_73: ; I - lntick 1, 8, 0, 3 - lntick 2, 3, 2, 5 - lntick 1, 2, 0, 3 .ch_74: ; J gptick 31, 6, 88 lntick 2, 8, 0, 3 @@ -610,8 +622,6 @@ diff16 "font02.chars: ",0,$ gptick 14, 0, 89 lntick 1, 3, 2, 6 ritick 0, 8, 0 -.ch_135: ; ZE - ritick 3, 5, 0 .ch_157: ; AE gptick 8, 1, 64 gptick 10, 6, 65 diff --git a/kernel/branches/Kolibri-A/trunk/init.inc b/kernel/branches/Kolibri-A/trunk/init.inc index 0224bb40ad..c5180a2c1c 100644 --- a/kernel/branches/Kolibri-A/trunk/init.inc +++ b/kernel/branches/Kolibri-A/trunk/init.inc @@ -121,7 +121,7 @@ init_mem: dec ecx jnz .map_kernel_tabs -; map pagetables to linear space +; map pagetables to linear space! mov dword [sys_pgdir-OS_BASE+(page_tabs shr 20)], sys_pgdir+PG_SW-OS_BASE mov edi, (sys_pgdir-OS_BASE) @@ -149,7 +149,7 @@ init_page_map: mov edi, sys_pgmap-OS_BASE mov ebx, ecx - shr ecx, 5 + shr ecx, 5 ; 32 pagebits per dw xor eax, eax rep stosd diff --git a/kernel/branches/Kolibri-A/trunk/kernel.asm b/kernel/branches/Kolibri-A/trunk/kernel.asm index d82c0b1559..2bcc7e0126 100644 --- a/kernel/branches/Kolibri-A/trunk/kernel.asm +++ b/kernel/branches/Kolibri-A/trunk/kernel.asm @@ -1,6 +1,6 @@ ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; ;; -;; Copyright (C) KolibriOS team 2004-2010. All rights reserved. +;; Copyright (C) KolibriOS team 2004-2013. All rights reserved. ;; PROGRAMMING: ;; Ivan Poddubny ;; Marat Zakiyanov (Mario79) @@ -87,7 +87,6 @@ pci_data_sel equ (pci_data_32-gdts) ;; Included files: ;; ;; Kernel16.inc -;; - Booteng.inc English text for bootup ;; - Bootcode.inc Hardware setup ;; - Pci16.inc PCI functions ;; @@ -116,14 +115,12 @@ use16 org 0x0 jmp start_of_code -version db 'Kolibri OS version 0.7.7.0+ ',13,10,13,10,0 +version db 'Kolibri-A version 0.1.0.0 ',13,10,13,10,0 -;include "boot/bootstr.inc" ; language-independent boot messages +diff16 "preboot start: ",0,$ include "boot/preboot.inc" -include "boot/booteng.inc" ; english system boot messages diff16 "bootcode start: ",0,$ - include "boot/bootcode.inc" ; 16 bit system boot code diff16 "pci16 start: ",0,$ @@ -252,6 +249,8 @@ end if lgdt [gdts] jmp pword os_code:high_code +diff16 "32-bit init size ",B32,$ + align 4 bios32_entry dd ? tmp_page_tabs dd ? @@ -478,7 +477,7 @@ high_code: stdcall kernel_alloc, (unpack.LZMA_BASE_SIZE+(unpack.LZMA_LIT_SIZE shl \ (unpack.lc+unpack.lp)))*4 - mov [unpack.p], eax + mov [unpack.p], eax ; unpacker.inc call init_events mov eax, srv.fd-SRV_FD_OFFSET diff --git a/kernel/branches/Kolibri-A/trunk/kernel32.inc b/kernel/branches/Kolibri-A/trunk/kernel32.inc index 7de782ddf2..3c438e8cdd 100644 --- a/kernel/branches/Kolibri-A/trunk/kernel32.inc +++ b/kernel/branches/Kolibri-A/trunk/kernel32.inc @@ -219,7 +219,7 @@ include "fs/ext2.inc" ; read / write for ext2 filesystem ; sound -include "sound/playnote.inc" ; player Note for Speaker PC +;include "sound/playnote.inc" ; player Note for Speaker PC ;include "sound/FHT.inc" ; fast Fourier transform routines ; display diff --git a/kernel/branches/Kolibri-A/trunk/memmap.inc b/kernel/branches/Kolibri-A/trunk/memmap.inc index bd11380dc4..c73acd1aa7 100644 --- a/kernel/branches/Kolibri-A/trunk/memmap.inc +++ b/kernel/branches/Kolibri-A/trunk/memmap.inc @@ -267,9 +267,7 @@ ; 0x805FF000 -> 5FFF80 TSS ; 0x80600000 -> 601FFF i/o maps -; 0x80800000 -> kernel heap -; 0x80FFFFFF heap min limit -; 0xEFFFFFFF heap max limit +; 0x80800000 ->827FFFFF kernel heap ; 0xF0000000 -> 0xF1FFFFFF PCI-express extended config space ; 0xFD000000 -> 0xFD3FFFFF static system buffer 4Mb diff --git a/kernel/branches/Kolibri-A/trunk/video/vesa20.inc b/kernel/branches/Kolibri-A/trunk/video/vesa20.inc index 8a0e3a22f9..856428ff1c 100644 --- a/kernel/branches/Kolibri-A/trunk/video/vesa20.inc +++ b/kernel/branches/Kolibri-A/trunk/video/vesa20.inc @@ -445,7 +445,7 @@ align 4 .invert_force: mov ecx, [ebx+eax*4] xor ecx, 0x00FFFFFF - or ecx, 0x01000000 ; keep bit[24] high ! + bts ecx, 24 ; keep bit[24] high ! align 4 .putpixel: mov [ebx+eax*4], ecx @@ -956,6 +956,7 @@ bgr_cur_line rd 1920 ; maximum width of screen bgr_next_line rd 1920 endg + smooth_line: mov al, [esi+2] shl eax, 16 @@ -1019,6 +1020,28 @@ align 4 overlapping_of_points_ptr dd overlapping_of_points endg +align 16 +overlapping_of_points_mmx: + movd mm0, eax + movd mm4, eax + movd mm1, ebx + pxor mm2, mm2 + punpcklbw mm0, mm2 + punpcklbw mm1, mm2 + psubw mm1, mm0 + movd mm3, ecx + psrld mm3, 24 + packuswb mm3, mm3 + packuswb mm3, mm3 + pmullw mm1, mm3 + psrlw mm1, 8 + packuswb mm1, mm2 + paddb mm4, mm1 + movd eax, mm4 + ret + + + init_background: mov edi, BgrAuxTable xor edx, edx @@ -1040,25 +1063,7 @@ init_background: @@: ret -align 16 -overlapping_of_points_mmx: - movd mm0, eax - movd mm4, eax - movd mm1, ebx - pxor mm2, mm2 - punpcklbw mm0, mm2 - punpcklbw mm1, mm2 - psubw mm1, mm0 - movd mm3, ecx - psrld mm3, 24 - packuswb mm3, mm3 - packuswb mm3, mm3 - pmullw mm1, mm3 - psrlw mm1, 8 - packuswb mm1, mm2 - paddb mm4, mm1 - movd eax, mm4 - ret + ;diff16 "VESA2 code end ",0,$ diff10 "VESA2 code size",get_pixel,$