Главная страница


ru.linux

 
 - RU.LINUX ---------------------------------------------------------------------
 From : Sergey Lentsov                       2:4615/71.10   28 Mar 2002  17:36:04
 To : All
 Subject : URL: http://www.lwn.net/2002/0328/kernel.php3
 -------------------------------------------------------------------------------- 
 
    [1][LWN Logo] [2][oasisi.php?s=5&w=468&h=60] 
    [LWN.net]
 
    Sections:
     [3]Main page
     [4]Security
     Kernel
     [5]Distributions
     [6]Development
     [7]Commerce
     [8]Linux in the news
     [9]Announcements
     [10]Letters
    [11]All in one big page
 
    See also: [12]last week's Kernel page.
 
 Kernel development
 
    The current development kernel release is 2.5.7. Linus is on vacation,
    so no 2.5.8 prepatches have been released.
 
    Dave Jones released [13]2.5.7-dj1 on March 21. "Resync, add compile
    fixes, simmer for 30 mins on low heat. Add random pending patches to
    taste. Still untested beyond 'it compiles', handle with care."
 
    Here is [14]Guillaume Boissiere's 2.5 status summary for March 27.
 
    The current stable kernel release is 2.4.18; the current 2.4.19
    prepatch from Marcelo remains [15]2.4.19-pre4; released on March 20.
 
    Alan Cox's latest prepatch is [16]2.4.19-pre4-ac2. It includes a great
    many fixes and a lot of USB updates, but there have been no major
    changes since the new IDE code went in last week.
 
    When close() goes bad. The close() system call is defined with the
    usual sort of return value: zero on success, nonzero otherwise. Most
    programmers do not look too closely at the return value from close();
    after all, when you are closing a file descriptor, the useful work has
    generally been accomplished. But a close can return a failure code.
    This code does not generally refer to the close operation itself
    (which must succeed); instead, it can be used to indicate a failure in
    some other, perhaps related device operation. A CDROM driver could
    return a failure status if it is unable to unlock the drive door, for
    example. Other devices may still have operations outstanding, and the
    return value from close() is the only way to report problems with
    those operations.
 
    Inside the kernel, close() maps to a function called release() in the
    file_operations structure. That function, too, has a return value. So
    Axel Kittenberger was surprised to find out that there was no
    connection between the release() return value and what the application
    gets back from close(). Instead, that value is discarded, and close()
    always succeeds. He has posted [17]a patch which fixes the situation
    by passing the release() return value through.
 
    Not everybody agrees that this is the right thing to do,
    interestingly. It has been stated that the fsync() call should be used
    by applications which are interested in any last-minute errors. But
    that approach doesn't address errors that happen in the close process
    itself. It is also a little strange to have return values from the
    operation that do not mean anything. So, while there are people who
    suggest that the release() function should be changed to return void,
    it's probably more likely that this patch will be applied.
 
    Straightening out the header files. People who dig around in the
    kernel source code tend to notice one thing early on: the header files
    are a bit of a mess. Figuring out which headers to include - and in
    which order - can be a pain. And it often seems necessary to include a
    large number of (seemingly) unrelated files to get a piece of code to
    compile.
 
    Daniel Phillips has started attacking one of the header file problems:
    the unstructured intermixing of definitions of data structures and the
    functions that use those structures. Many of the header files have
    "evolved" over time into fairly long and twisted things; programmers
    have thrown new definitions in over the years, often without any sort
    of overall design for the header file itself.
 
    Numerous problems have their roots in this untidiness, but Daniel has
    picked out one in particular: it can be hard to define inline
    functions that use certain kernel data structures. Such functions
    often get defined before the structures they reference; this, of
    course, does not work if the function needs to know anything specific
    about the data structure. Rearranging the definitions can be hard, so
    programmers tend to give up on inline functions and fall back on the
    use of macros. Macros work, but they are inelegant, and, crucially,
    they do not offer the same sort of type checking that inline functions
    do.
 
    The solution, according to Daniel, is to split out the definitions of
    fundamental data structures into their own header files. These small
    headers can then be placed early in the list of files to include, and
    their structures are available for use in inline functions later. He
    has [18]posted a patch which makes this change for struct page, a
    fundamental data structure used in the management of physical memory.
    This change allows a couple of former macros (_pa, which converts
    kernel-space virtual addresses to physical addresses, and _va, which
    does the opposite) into inline functions. Says Daniel:
 
      As soon as I had the inline version of __pa, it picked up an
      oversight where Jeff [Dike] uses virtual addresses in his page
      tables instead of physical addresses. It works in the case of uml,
      but it's quite unexpected and has only gone unnoticed this long
      because of weak type checking due to use of macros.
 
    The code changes required for this sort of patch are not small, since
    a fair amount of rearranging can be required. It appears that it may
    be worth the effort, though. For any ambitious folk who would like to
    take on other kernel headers, Daniel has [19]posted his algorithm for
    accomplishing the task. It is, he says, "slightly painful, but not
    horribly excruciatingly painful." With such inspirational words, who
    can resist the urge to jump in and help out?
 
    Other patches and updates released this week include:
 
    Kernel trees:
      * J.A. Magallon's latest is [20]2.4.19-pre4-jam1.
      * Marc-Christian Petersen has released [21]2.4.18-WOLK3.1. This
        kernel now has over 90 patches; some of the latest additions are
        TUX, User-mode Linux, the Linux Trace toolkit, and more.
 
    Core kernel code:
      * Hubertus Franke has [22]posted a patch to the code that assigns
        IDs to new processes. The current method of finding an unused PID
        is very inefficient, especially if there are large numbers of
        processes running on the system. With this patch, process ID
        assignment is faster on systems with at least 25,000 processes
        running - so most people won't need it for their desktop systems.
      * Andrew Morton has [23]released a new set of reworked VM patches
        (as originally written by Andrea Arcangeli and covered here
        [24]last week).
      * A [25]new radix tree page cache patch has been released by
        Christoph Hellwig.
 
    Device drivers
      * Jens Axboe has [26]released support for "Mt. Rainier" CD-RW
        drives. See [27]here for the latest version.
      * Richard Gooch has [28]released devfsd v1.3.25 and [29]devfs
        199.10.
      * Patrick Mochel has [30]updated his device model code to build an
        ordered list of all devices on the system. A set of functions has
        been supplied which can use that list to suspend, resume, or shut
        down all devices in the system in the proper order.
 
    Filesystems:
      * Roger Gammans has [31]written some documentation for the JBD
        (journaling) layer.
      * Anton Altaparmakov has [32]released a completely rewritten,
        read-only NT filesystem implementation.
      * [33]Version 0.8.23 of the access control list patch has been
        released by Andreas Gruenbacher.
 
    Kernel building:
      * Roman Zippel has [34]released a specification for his new kernel
        configuration system.
 
    Miscellaneous:
      * Keith Owens has released [35]modutils 2.4.15.
      * Here is [36]the latest maintainers file from Denis Vlasenko.
 
    Ports:
      * Here is [37]the announcement for the latest NCR Voyager port from
        James Bottomley.
 
    Section Editor: [38]Jonathan Corbet
    March 28, 2002
 
                                Sponsored Link
 
    [39]Your Text Ad Here
 
    Purchase your own text ad with our self-serve advertising system.
 
    For other kernel news, see:
      * [40]Kernel traffic
      * [41]Kernel Newsflash
      * [42]Kernel Trap
      * [43]Linux 2.5.x Porting help
      * [44]2.5 Status
    
    Other resources:
      * [45]Kernel Source Reference
      * [46]L-K mailing list FAQ
      * [47]Linux-MM
      * [48]Linux Scalability Effort
      * [49]Kernel Newbies
      * [50]Linux Device Drivers
    
    
 
                                                   [51]Next: Distributions
 
    [52]Eklektix, Inc. Linux powered! Copyright Л 2002 [53]Eklektix, Inc.,
    all rights reserved
    Linux (R) is a registered trademark of Linus Torvalds
 
 References
 
    1. http://lwn.net/
    2. http://oasis.lwn.net/oasisc.php?s=5&w=468&h=60
    3. http://lwn.net/2002/0328/
    4. http://lwn.net/2002/0328/security.php3
    5. http://lwn.net/2002/0328/dists.php3
    6. http://lwn.net/2002/0328/devel.php3
    7. http://lwn.net/2002/0328/commerce.php3
    8. http://lwn.net/2002/0328/press.php3
    9. http://lwn.net/2002/0328/announce.php3
   10. http://lwn.net/2002/0328/letters.php3
   11. http://lwn.net/2002/0328/bigpage.php3
   12. http://lwn.net/2002/0321/kernel.php3
   13. http://lwn.net/2002/0328/a/2.5.7-dj1.php3
   14. http://lwn.net/2002/0328/a/2.5-status.php3
   15. http://lwn.net/2002/0328/a/2.4.19-pre4.php3
   16. http://lwn.net/2002/0328/a/2.4.19-pre4-ac2.php3
   17. http://lwn.net/2002/0328/a/close-retval.php3
   18. http://lwn.net/2002/0328/a/struct-page-early.php3
   19. http://lwn.net/2002/0328/a/header-algorithm.php3
   20. http://lwn.net/2002/0328/a/2.4.19-pre4-jam1.php3
   21. http://lwn.net/2002/0328/a/2.4.18-WOLK3.1.php3
   22. http://lwn.net/2002/0328/a/getpid.php3
   23. http://lwn.net/2002/0328/a/aa-patches.php3
   24. http://lwn.net/2002/0321/
   25. http://lwn.net/2002/0328/a/ratcache.php3
   26. http://lwn.net/2002/0328/a/rainier.php3
   27. http://lwn.net/2002/0328/a/rainier2.php3
   28. http://lwn.net/2002/0328/a/devfsd.php3
   29. http://lwn.net/2002/0328/a/devfs.php3
   30. http://lwn.net/2002/0328/a/device-model.php3
   31. http://lwn.net/2002/0328/a/jbd-doc.php3
   32. http://lwn.net/2002/0328/a/ntfs.php3
   33. http://lwn.net/2002/0328/a/acl.php3
   34. http://lwn.net/2002/0328/a/lc-spec.php3
   35. http://lwn.net/2002/0328/a/modutils.php3
   36. http://lwn.net/2002/0328/a/maintainers.php3
   37. http://lwn.net/2002/0328/a/voyager.php3
   38. mailto:lwn@lwn.net
   39.
 http://oasis.lwn.net/oasisc.php?s=5&c=5&cb=950707315&url=http%3A%2F%2Flwn.net%2F
 corp%2Fadvertise%2Ftext%2F
   40. http://kt.zork.net/
   41. http://www.atnf.csiro.au/~rgooch/linux/docs/kernel-newsflash.html
   42. http://www.kerneltrap.com/
   43. http://www.osdl.org/archive/rddunlap/linux-port-25x.html
   44. http://kernelnewbies.org/status/
   45. http://lksr.org/
   46. http://www.tux.org/lkml/
   47. http://www.linux.eu.org/Linux-MM/
   48. http://lse.sourceforge.net/
   49. http://www.kernelnewbies.org/
   50. http://www.xml.com/ldd/chapter/book/index.html
   51. http://lwn.net/2002/0328/dists.php3
   52. http://www.eklektix.com/
   53. http://www.eklektix.com/
 
 --- ifmail v.2.14.os7-aks1
  * Origin: Unknown (2:4615/71.10@fidonet)
 
 

Вернуться к списку тем, сортированных по: возрастание даты  уменьшение даты  тема  автор 

 Тема:    Автор:    Дата:  
 URL: http://www.lwn.net/2002/0328/kernel.php3   Sergey Lentsov   28 Mar 2002 17:36:04 
Архивное /ru.linux/198615b1d8594.html, оценка 2 из 5, голосов 10
Яндекс.Метрика
Valid HTML 4.01 Transitional