RE: Question regarding User Space and the Kernel

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 




----Original Message----
From: kernelnewbies-bounce@xxxxxxxxxxxx
[mailto:kernelnewbies-bounce@xxxxxxxxxxxx]On Behalf Of Mulyadi Santosa
Sent: Wednesday, November 21, 2007 9:49 AM
To: Sikandar Khan
Cc: kernelnewbies
Subject: Re: Question regarding User Space and the Kernel

> Hi...
>> 1) Can the kernel access User Address Space. Yes
>> If yes thats wat i found from
>> net ( but it is poorly written driver if it allows the same)
>> then why cant the kernel directly copy data from the user . Why do
>> we need copy_to_user and copy_from_user.
>> Is it because some  protection  mechanisms.
>> 
> we need to make sure the user space address is valid. It means:
> 1. It is within valid user space address range (in 3:1 VM split, it's
> 0-3 GB)
> 2. It is within valid segment range (mentioned in related segment
> descriptor)

3. It is not swapped out to disk.

Thanks,

Rajat
��.n��������+%����w�j)p���{.n����z�ޖw�n'���q���b�������v��m�����Y�����


[Index of Archives]     [Newbies FAQ]     [Linux Kernel Mentors]     [Linux Kernel Development]     [IETF Annouce]     [Git]     [Networking]     [Security]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux RAID]     [Linux SCSI]     [Linux ACPI]
  Powered by Linux