{"id":105081,"date":"2022-09-13T09:36:41","date_gmt":"2022-09-13T07:36:42","guid":{"rendered":"https:\/\/prohoster.info\/blog\/novosti-interneta\/wd-razrabatyvaet-nvme-drajver-na-yazyke-rust-eksperimenty-s-rust-vo-freebsd"},"modified":"2022-09-13T09:36:41","modified_gmt":"2022-09-13T07:36:42","slug":"wd-razrabatyvaet-nvme-drajver-na-yazyke-rust-eksperimenty-s-rust-vo-freebsd","status":"publish","type":"post","link":"https:\/\/prohoster.info\/en\/blog\/news\/wd-razrabatyvaet-nvme-drajver-na-yazyke-rust-eksperimenty-s-rust-vo-freebsd","title":{"rendered":"WD is developing an NVMe driver in Rust. Experiments with Rust in FreeBSD","gt_translate_keys":[{"key":"rendered","format":"text"}]},"content":{"rendered":"<p>At the ongoing Linux Plumbers Conference 2022, an engineer from Western Digital presented a talk about the development of an experimental driver for NVMe (NVM Express) SSDs, written in Rust and operating at the Linux kernel level. Although the project is still in its early stages, testing has shown that the performance of the NVMe driver in Rust matches that of the existing NVMe driver in the kernel, written in C.      <center><img decoding=\"async\" alt=\"WD is developing an NVMe driver in Rust. Experiments with Rust in FreeBSD\" src=\"\/wp-content\/uploads\/2022\/09\/0c49f6bb2485871524d0f0427f41ad4d.jpg\" style=\"display:block;margin: 0 auto;\" \/><\/center>    <center><img decoding=\"async\" alt=\"WD is developing an NVMe driver in Rust. Experiments with Rust in FreeBSD\" src=\"\/wp-content\/uploads\/2022\/09\/62fa18285c0eab993e911a5345e8e228.jpg\" style=\"display:block;margin: 0 auto;\" \/><\/center>    <\/p>\n<p>The report states that the current NVMe driver in C fully satisfies developers, but the NVMe subsystem is a good platform to explore the feasibility of developing drivers in Rust, as it is fairly simple, widely used, has high performance requirements, has a proven reference implementation for comparison, and supports multiple interfaces (dev, pci, dma, blk-mq, gendisk, sysfs).     <\/p>\n<p>It is noted that the PCI NVMe driver in Rust already provides the necessary functionality for operation, but it is not yet ready for widespread use, as it requires additional modifications. Future plans include removing existing unsafe blocks from the code, supporting device removal operations and driver unloading, supporting the sysfs interface, implementing deferred initialization, creating a driver for blk-mq, and experimenting with asynchronous programming models for queue_rq.        <center>  <div class=\"youtube-placeholder\" data-id=\"Xw9pKeJ-4Bw\" onclick=\"loadVideo(this)\">\r\n        <img decoding=\"async\" src=\"https:\/\/img.youtube.com\/vi\/Xw9pKeJ-4Bw\/hqdefault.jpg\" alt=\"Play video\" loading=\"lazy\" width=\"480\" height=\"360\" style=\"width:100%;height:auto;\">\r\n        <div class=\"play-button\"><\/div>\r\n    <\/div>  <\/center>    <\/p>\n<p>Additionally, it is worth mentioning the experiments conducted by NCC Group on developing drivers in Rust for the FreeBSD kernel. As an example, a simple echo driver is examined in detail, which returns the data written to the file \/dev\/rustmodule. In the next phase of experiments, NCC Group is considering the possibility of rewriting kernel core components in Rust to enhance the security of network and file operations.     <\/p>\n<p>However, despite demonstrating the possibility of creating simple modules in Rust, a more integrated approach of Rust into the FreeBSD kernel will require additional work. For instance, there is a need to create a set of abstraction layers over the subsystems and structures of the kernel, similar to the enhancements prepared by the Rust for Linux project. Further experiments with the Illumos kernel are also planned to identify common Rust abstractions that could be used in Rust-written drivers for Linux, BSD, and Illumos.    <\/p>\n<p>According to Microsoft and Google, around 70% of vulnerabilities in their software products are due to unsafe memory handling. It's believed that using Rust will help reduce the risk of vulnerabilities caused by unsafe memory operations and eliminate errors such as dereferencing freed memory and buffer overflows.     <\/p>\n<p>Safe memory handling in Rust is ensured at compile time through reference checking, ownership tracking of objects, and considerations of object lifetimes (scope), as well as runtime checks for correctness in memory access. Rust also provides protections against integer overflows, requires variables to be initialized before use, manages errors more effectively in the standard library, employs immutability by default for references and variables, and offers strong static typing to minimize logical errors.<br \/>\n<br \/>Source: <a content=\"nofollow\" rel=\"nofollow\" href=\"https:\/\/www.opennet.ru\/opennews\/art.shtml?num=57774\">opennet.ru<\/a> <\/p>","protected":false,"gt_translate_keys":[{"key":"rendered","format":"html"}]},"excerpt":{"rendered":"<p>\u041d\u0430 \u043f\u0440\u043e\u0445\u043e\u0434\u044f\u0449\u0435\u0439 \u0432 \u044d\u0442\u0438 \u0434\u043d\u0438 \u043a\u043e\u043d\u0444\u0435\u0440\u0435\u043d\u0446\u0438\u0438 Linux Plumbers 2022 \u0438\u043d\u0436\u0435\u043d\u0435\u0440 \u0438\u0437 \u043a\u043e\u043c\u043f\u0430\u043d\u0438\u0438 Western Digital \u0432\u044b\u0441\u0442\u0443\u043f\u0438\u043b \u0441 \u0434\u043e\u043a\u043b\u0430\u0434\u043e\u043c \u043e \u0440\u0430\u0437\u0440\u0430\u0431\u043e\u0442\u043a\u0435 \u044d\u043a\u0441\u043f\u0435\u0440\u0438\u043c\u0435\u043d\u0442\u0430\u043b\u044c\u043d\u043e\u0433\u043e \u0434\u0440\u0430\u0439\u0432\u0435\u0440\u0430 \u0434\u043b\u044f SSD-\u043d\u0430\u043a\u043e\u043f\u0438\u0442\u0435\u043b\u0435\u0439 \u0441 \u0438\u043d\u0442\u0435\u0440\u0444\u0435\u0439\u0441\u043e\u043c NVM-Express (NVMe), \u043d\u0430\u043f\u0438\u0441\u0430\u043d\u043d\u043e\u0433\u043e \u043d\u0430 \u044f\u0437\u044b\u043a\u0435 Rust \u0438 \u0440\u0430\u0431\u043e\u0442\u0430\u044e\u0449\u0435\u0433\u043e \u043d\u0430 \u0443\u0440\u043e\u0432\u043d\u0435 \u044f\u0434\u0440\u0430 Linux. \u041d\u0435\u0441\u043c\u043e\u0442\u0440\u044f \u043d\u0430 \u0442\u043e, \u0447\u0442\u043e \u043f\u0440\u043e\u0435\u043a\u0442 \u043f\u043e\u043a\u0430 \u043d\u0430\u0445\u043e\u0434\u0438\u0442\u0441\u044f \u043d\u0430 \u0440\u0430\u043d\u043d\u0435\u043c \u044d\u0442\u0430\u043f\u0435 \u0440\u0430\u0437\u0432\u0438\u0442\u0438\u044f, \u043f\u0440\u043e\u0432\u0435\u0434\u0451\u043d\u043d\u043e\u0435 \u0442\u0435\u0441\u0442\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u0435 \u043f\u043e\u043a\u0430\u0437\u0430\u043b\u043e, \u0447\u0442\u043e \u043f\u0440\u043e\u0438\u0437\u0432\u043e\u0434\u0438\u0442\u0435\u043b\u044c\u043d\u043e\u0441\u0442\u044c NVMe-\u0434\u0440\u0430\u0439\u0432\u0435\u0440\u0430 \u043d\u0430 [&hellip;]<\/p>\n","protected":false,"gt_translate_keys":[{"key":"rendered","format":"html"}]},"author":1,"featured_media":105082,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[702],"tags":[],"class_list":["post-105081","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-news"],"aioseo_notices":[],"aioseo_head":"\n\t\t<!-- All in One SEO 5.0.2 - aioseo.com -->\n\t<meta name=\"description\" content=\"\u041d\u0430 \u043f\u0440\u043e\u0445\u043e\u0434\u044f\u0449\u0435\u0439 \u0432 \u044d\u0442\u0438 \u0434\u043d\u0438 \u043a\u043e\u043d\u0444\u0435\u0440\u0435\u043d\u0446\u0438\u0438 Linux Plumbers 2022 \u0438\u043d\u0436\u0435\u043d\u0435\u0440 \u0438\u0437 \u043a\u043e\u043c\u043f\u0430\u043d\u0438\u0438 Western Digital \u0432\u044b\u0441\u0442\u0443\u043f\u0438\u043b \u0441 \u0434\u043e\u043a\u043b\u0430\u0434\u043e\u043c \u043e \u0440\u0430\u0437\u0440\u0430\u0431\u043e\u0442\u043a\u0435 \u044d\u043a\u0441\u043f\u0435\u0440\u0438\u043c\u0435\u043d\u0442\u0430\u043b\u044c\u043d\u043e\u0433\u043e \u0434\u0440\u0430\u0439\u0432\u0435\u0440\u0430 \u0434\u043b\u044f SSD-\u043d\u0430\u043a\u043e\u043f\u0438\u0442\u0435\u043b\u0435\u0439 \u0441 \u0438\u043d\u0442\u0435\u0440\u0444\u0435\u0439\u0441\u043e\u043c NVM-Express (NVMe).\" \/>\n\t<meta name=\"robots\" content=\"max-image-preview:large\" \/>\n\t<meta name=\"author\" content=\"Yuri Gagarin\"\/>\n\t<link rel=\"canonical\" href=\"https:\/\/prohoster.info\/en\/blog\/news\/wd-razrabatyvaet-nvme-drajver-na-yazyke-rust-eksperimenty-s-rust-vo-freebsd\" \/>\n\t<meta name=\"generator\" content=\"All in One SEO (AIOSEO) 5.0.2\" \/>\n\t\t<meta property=\"og:locale\" content=\"en_US\" \/>\n\t\t<meta property=\"og:site_name\" content=\"ProHoster | \u041a\u0443\u043f\u0438\u0442\u044c \u043d\u0430\u0434\u0435\u0436\u043d\u044b\u0439 \u0445\u043e\u0441\u0442\u0438\u043d\u0433 \u0434\u043b\u044f \u0441\u0430\u0439\u0442\u043e\u0432 \u0441 \u0437\u0430\u0449\u0438\u0442\u043e\u0439 \u043e\u0442 DDoS, VPS VDS \u0441\u0435\u0440\u0432\u0435\u0440\u044b\" \/>\n\t\t<meta property=\"og:type\" content=\"article\" \/>\n\t\t<meta property=\"og:title\" content=\"\ud83e\udd47WD \u0440\u0430\u0437\u0440\u0430\u0431\u0430\u0442\u044b\u0432\u0430\u0435\u0442 NVMe-\u0434\u0440\u0430\u0439\u0432\u0435\u0440 \u043d\u0430 \u044f\u0437\u044b\u043a\u0435 Rust. \u042d\u043a\u0441\u043f\u0435\u0440\u0438\u043c\u0435\u043d\u0442\u044b \u0441 Rust \u0432\u043e FreeBSD | ProHoster\" \/>\n\t\t<meta property=\"og:description\" content=\"\u041d\u0430 \u043f\u0440\u043e\u0445\u043e\u0434\u044f\u0449\u0435\u0439 \u0432 \u044d\u0442\u0438 \u0434\u043d\u0438 \u043a\u043e\u043d\u0444\u0435\u0440\u0435\u043d\u0446\u0438\u0438 Linux Plumbers 2022 \u0438\u043d\u0436\u0435\u043d\u0435\u0440 \u0438\u0437 \u043a\u043e\u043c\u043f\u0430\u043d\u0438\u0438 Western Digital \u0432\u044b\u0441\u0442\u0443\u043f\u0438\u043b \u0441 \u0434\u043e\u043a\u043b\u0430\u0434\u043e\u043c \u043e \u0440\u0430\u0437\u0440\u0430\u0431\u043e\u0442\u043a\u0435 \u044d\u043a\u0441\u043f\u0435\u0440\u0438\u043c\u0435\u043d\u0442\u0430\u043b\u044c\u043d\u043e\u0433\u043e \u0434\u0440\u0430\u0439\u0432\u0435\u0440\u0430 \u0434\u043b\u044f SSD-\u043d\u0430\u043a\u043e\u043f\u0438\u0442\u0435\u043b\u0435\u0439 \u0441 \u0438\u043d\u0442\u0435\u0440\u0444\u0435\u0439\u0441\u043e\u043c NVM-Express (NVMe).\" \/>\n\t\t<meta property=\"og:url\" content=\"https:\/\/prohoster.info\/en\/blog\/news\/wd-razrabatyvaet-nvme-drajver-na-yazyke-rust-eksperimenty-s-rust-vo-freebsd\" \/>\n\t\t<meta property=\"og:image\" content=\"https:\/\/prohoster.info\/wp-content\/uploads\/2021\/11\/logo-350.jpg\" \/>\n\t\t<meta property=\"og:image:secure_url\" content=\"https:\/\/prohoster.info\/wp-content\/uploads\/2021\/11\/logo-350.jpg\" \/>\n\t\t<meta property=\"og:image:width\" content=\"350\" \/>\n\t\t<meta property=\"og:image:height\" content=\"350\" \/>\n\t\t<meta property=\"article:published_time\" content=\"2022-09-13T07:36:42+00:00\" \/>\n\t\t<meta property=\"article:modified_time\" content=\"2022-09-13T07:36:42+00:00\" \/>\n\t\t<meta property=\"article:publisher\" content=\"https:\/\/www.facebook.com\/prohoster\" \/>\n\t\t<meta property=\"article:author\" content=\"https:\/\/www.facebook.com\/prohoster\" \/>\n\t\t<!-- All in One SEO -->\n\n","aioseo_head_json":{"title":"\ud83e\udd47WD is developing an NVMe driver in Rust. Experiments with Rust in FreeBSD | ProHoster","description":"At the ongoing Linux Plumbers Conference 2022, an engineer from Western Digital presented a talk on developing an experimental driver for SSDs with an NVMe interface.","canonical_url":"https:\/\/prohoster.info\/en\/blog\/news\/wd-razrabatyvaet-nvme-drajver-na-yazyke-rust-eksperimenty-s-rust-vo-freebsd","robots":"max-image-preview:large","keywords":"","webmasterTools":{"miscellaneous":""},"schema":null,"og:locale":"en_US","og:site_name":"ProHoster | \u041a\u0443\u043f\u0438\u0442\u044c \u043d\u0430\u0434\u0435\u0436\u043d\u044b\u0439 \u0445\u043e\u0441\u0442\u0438\u043d\u0433 \u0434\u043b\u044f \u0441\u0430\u0439\u0442\u043e\u0432 \u0441 \u0437\u0430\u0449\u0438\u0442\u043e\u0439 \u043e\u0442 DDoS, VPS VDS \u0441\u0435\u0440\u0432\u0435\u0440\u044b","og:type":"article","og:title":"\ud83e\udd47WD \u0440\u0430\u0437\u0440\u0430\u0431\u0430\u0442\u044b\u0432\u0430\u0435\u0442 NVMe-\u0434\u0440\u0430\u0439\u0432\u0435\u0440 \u043d\u0430 \u044f\u0437\u044b\u043a\u0435 Rust. \u042d\u043a\u0441\u043f\u0435\u0440\u0438\u043c\u0435\u043d\u0442\u044b \u0441 Rust \u0432\u043e FreeBSD | ProHoster","og:description":"\u041d\u0430 \u043f\u0440\u043e\u0445\u043e\u0434\u044f\u0449\u0435\u0439 \u0432 \u044d\u0442\u0438 \u0434\u043d\u0438 \u043a\u043e\u043d\u0444\u0435\u0440\u0435\u043d\u0446\u0438\u0438 Linux Plumbers 2022 \u0438\u043d\u0436\u0435\u043d\u0435\u0440 \u0438\u0437 \u043a\u043e\u043c\u043f\u0430\u043d\u0438\u0438 Western Digital \u0432\u044b\u0441\u0442\u0443\u043f\u0438\u043b \u0441 \u0434\u043e\u043a\u043b\u0430\u0434\u043e\u043c \u043e \u0440\u0430\u0437\u0440\u0430\u0431\u043e\u0442\u043a\u0435 \u044d\u043a\u0441\u043f\u0435\u0440\u0438\u043c\u0435\u043d\u0442\u0430\u043b\u044c\u043d\u043e\u0433\u043e \u0434\u0440\u0430\u0439\u0432\u0435\u0440\u0430 \u0434\u043b\u044f SSD-\u043d\u0430\u043a\u043e\u043f\u0438\u0442\u0435\u043b\u0435\u0439 \u0441 \u0438\u043d\u0442\u0435\u0440\u0444\u0435\u0439\u0441\u043e\u043c NVM-Express (NVMe).","og:url":"https:\/\/prohoster.info\/en\/blog\/news\/wd-razrabatyvaet-nvme-drajver-na-yazyke-rust-eksperimenty-s-rust-vo-freebsd","og:image":"https:\/\/prohoster.info\/wp-content\/uploads\/2021\/11\/logo-350.jpg","og:image:secure_url":"https:\/\/prohoster.info\/wp-content\/uploads\/2021\/11\/logo-350.jpg","og:image:width":350,"og:image:height":350,"article:published_time":"2022-09-13T07:36:42+00:00","article:modified_time":"2022-09-13T07:36:42+00:00","article:publisher":"https:\/\/www.facebook.com\/prohoster","article:author":"https:\/\/www.facebook.com\/prohoster"},"aioseo_meta_data":[],"gt_translate_keys":[{"key":"link","format":"url"}],"_links":{"self":[{"href":"https:\/\/prohoster.info\/en\/wp-json\/wp\/v2\/posts\/105081","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/prohoster.info\/en\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/prohoster.info\/en\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/prohoster.info\/en\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/prohoster.info\/en\/wp-json\/wp\/v2\/comments?post=105081"}],"version-history":[{"count":0,"href":"https:\/\/prohoster.info\/en\/wp-json\/wp\/v2\/posts\/105081\/revisions"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/prohoster.info\/en\/wp-json\/wp\/v2\/media\/105082"}],"wp:attachment":[{"href":"https:\/\/prohoster.info\/en\/wp-json\/wp\/v2\/media?parent=105081"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/prohoster.info\/en\/wp-json\/wp\/v2\/categories?post=105081"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/prohoster.info\/en\/wp-json\/wp\/v2\/tags?post=105081"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}