skip to main content
10.1145/1278480.1278534acmconferencesArticle/Chapter ViewAbstractPublication PagesdacConference Proceedingsconference-collections
Article

A system for coarse grained memory protection in tiny embedded processors

Authors Info & Claims
Published:04 June 2007Publication History

ABSTRACT

Many embedded systems contain resource constrained microcontrollers where applications, operating system components and device drivers reside within a single address space with no form of memory protection. Programming errors in one application can easily corrupt the state of the operating system and other applications on the microcontroller. In this paper we propose a system that provides memory protection in tiny embedded processors. Our system consists of a software run-time working with minimal low-cost architectural extensions to the processor core that prevents corruption of state by buggy applications. We restrict memory accesses and control flow of applications to protection domains within the address space. The software run-time consists of a Memory map: a flexible and efficient data structure that records ownership and layout information of the entire address space. Memory map checks are done for store instructions by hardware accelerators that significantly improve the performance of our system. We preserve control flow integrity by maintaining a Safe stack that stores return addresses in a protected memory region. Cross domain function calls are redirected through a software based jump table. Enhancements to the microcontroller call and return instructions use the jump table to track the current active domain. We have implemented our scheme on a VHDL model of ATMEGA103 microcontroller. Our evaluations show that embedded applications can enjoy the benefits of memory protection with minimal impact on performance and a modest increase in the area of the microcontroller.

References

  1. ARM7TDMI Technical Reference Manual. http://www.arm.com/pdfs/DDI0210C_7tdmi_r4pl_trm.pdf.Google ScholarGoogle Scholar
  2. D. Arora, A. Raghunathan, and N. K. Jha. Architectural support for safe software execution on embedded processors. In CODES+ISSS '06: Proc. 4th International Conference on Hardware/Software Codesign and System Synthesis, 2006. Google ScholarGoogle ScholarDigital LibraryDigital Library
  3. A. Dunkels, N. Finne, J. Eriksson, and T. Voigt. Run-time dynamic linking for reprogramming wireless sensor networks. In SenSys '06: Proc. 4th ACM Conference on Embedded Networked Sensor Systems, 2006. Google ScholarGoogle ScholarDigital LibraryDigital Library
  4. D. Gay, P. Levis, R. von Behren, and M. Welsh. The nesC language: A holistic approach to networked embedded systems. In PLDI '03: Proc. ACM SIGPLAN 2003 Conference on Programming Language Design and Implementation, 2003. Google ScholarGoogle ScholarDigital LibraryDigital Library
  5. C.-C. Han, R. Kumar, R. Shea, E. Kohler, and M. Srivastava. SOS: A dynamic operating system for sensor networks. In MobiSys '05: Proc. 3rd International Conference on Mobile Systems, Applications, and Services, 2005. Google ScholarGoogle ScholarDigital LibraryDigital Library
  6. J. Hill and D. Culler. Mica: A wireless platform for deeply embedded networks. In IEEE Micro., volume 22, pages 12--24, Nov/Dec 2002. Google ScholarGoogle ScholarDigital LibraryDigital Library
  7. A. Inc. ARM 940T Technical Reference Manual.Google ScholarGoogle Scholar
  8. R. Kumar, E. Kohler, and M. Srivastava. Harbor: Software based memory protection for sensor nodes. In IPSN '07: Proc. 6th International Symposium on Information Processing in Sensor Networks, 2007. Google ScholarGoogle ScholarDigital LibraryDigital Library
  9. P. Levis, D. Gay, and D. Culler. Active sensor networks. In NSDI '05: Proc. 2nd Symposium on Networked Systems Design and Implementation, 2005 Google ScholarGoogle ScholarDigital LibraryDigital Library
  10. P. Levis, D. Gay, V. Handziski, J. H. Hauer, B. Greenstein, M. Turon, J. Hui, K. Klues, C. Sharp, R. Szewczyk, J. Polastre, P. Buonadonna, L. Nachman, G. Tolle, D. Culler, and A. Wolisz. T2: A second generation OS for embedded sensor networks. Technical Report TKN-05-007, Telecommunication Networks Group, Technische Universität Berlin, 2005.Google ScholarGoogle Scholar
  11. G. C. Necula, S. McPeak, and W. Weimer. CCured: Type-safe retrofitting of legacy code. In POPL '02: Proc. 29th ACM SIGPLAN-SIGACT Symposium on Principles of Programming Languages, 2002. Google ScholarGoogle ScholarDigital LibraryDigital Library
  12. F. Qin, S. Lu, and Y. Zhou. Safemem: Exploiting ecc-memory for detecting memory leaks and memory corruption during production runs. In International Symposium on High-Performance Computer Architecture (HPCA), 2005. Google ScholarGoogle ScholarDigital LibraryDigital Library
  13. I. Technologies. TC1775: 32-Bit Single Chip Microcontroller.Google ScholarGoogle Scholar
  14. B. L. Titzer. Virgil: Objects on the head of a pin. In OOPSLA '06: Proc. 21st ACM SIGPLAN Conference on Object-Oriented Systems, Languages, and Applications, 2006. Google ScholarGoogle ScholarDigital LibraryDigital Library
  15. E. Witchel, J. Cates, and K. Asanović. Mondrian memory protection. In International Conference on Architectural Support for Programming Languages and Operating Systems (ASPLOS), 2002. Google ScholarGoogle ScholarDigital LibraryDigital Library
  16. Zigbee Consortium. www.zigbee.com.Google ScholarGoogle Scholar

Index Terms

  1. A system for coarse grained memory protection in tiny embedded processors

      Recommendations

      Comments

      Login options

      Check if you have access through your login credentials or your institution to get full access on this article.

      Sign in
      • Published in

        cover image ACM Conferences
        DAC '07: Proceedings of the 44th annual Design Automation Conference
        June 2007
        1016 pages
        ISBN:9781595936271
        DOI:10.1145/1278480

        Copyright © 2007 ACM

        Permission to make digital or hard copies of all or part of this work for personal or classroom use is granted without fee provided that copies are not made or distributed for profit or commercial advantage and that copies bear this notice and the full citation on the first page. Copyrights for components of this work owned by others than ACM must be honored. Abstracting with credit is permitted. To copy otherwise, or republish, to post on servers or to redistribute to lists, requires prior specific permission and/or a fee. Request permissions from [email protected]

        Publisher

        Association for Computing Machinery

        New York, NY, United States

        Publication History

        • Published: 4 June 2007

        Permissions

        Request permissions about this article.

        Request Permissions

        Check for updates

        Qualifiers

        • Article

        Acceptance Rates

        DAC '07 Paper Acceptance Rate152of659submissions,23%Overall Acceptance Rate1,770of5,499submissions,32%

        Upcoming Conference

        DAC '24
        61st ACM/IEEE Design Automation Conference
        June 23 - 27, 2024
        San Francisco , CA , USA

      PDF Format

      View or Download as a PDF file.

      PDF

      eReader

      View online with eReader.

      eReader