1<html><head><meta http-equiv="Content-Type" content="text/html; charset=ANSI_X3.4-1968"><title>nand_lock</title><meta name="generator" content="DocBook XSL Stylesheets V1.78.1"><link rel="home" href="index.html" title="MTD NAND Driver Programming Interface"><link rel="up" href="pubfunctions.html" title="Chapter 10. Public Functions Provided"><link rel="prev" href="API-nand-unlock.html" title="nand_unlock"><link rel="next" href="API-nand-scan-ident.html" title="nand_scan_ident"></head><body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF"><div class="navheader"><table width="100%" summary="Navigation header"><tr><th colspan="3" align="center"><span class="phrase">nand_lock</span></th></tr><tr><td width="20%" align="left"><a accesskey="p" href="API-nand-unlock.html">Prev</a> </td><th width="60%" align="center">Chapter 10. Public Functions Provided</th><td width="20%" align="right"> <a accesskey="n" href="API-nand-scan-ident.html">Next</a></td></tr></table><hr></div><div class="refentry"><a name="API-nand-lock"></a><div class="titlepage"></div><div class="refnamediv"><h2>Name</h2><p>nand_lock — 2 [REPLACEABLE] locks all blocks present in the device 3 </p></div><div class="refsynopsisdiv"><h2>Synopsis</h2><div class="funcsynopsis"><table border="0" class="funcprototype-table" summary="Function synopsis" style="cellspacing: 0; cellpadding: 0;"><tr><td><code class="funcdef">int <b class="fsfunc">nand_lock </b>(</code></td><td>struct mtd_info * <var class="pdparam">mtd</var>, </td></tr><tr><td> </td><td>loff_t <var class="pdparam">ofs</var>, </td></tr><tr><td> </td><td>uint64_t <var class="pdparam">len</var><code>)</code>;</td></tr></table><div class="funcprototype-spacer"> </div></div></div><div class="refsect1"><a name="idp1102750620"></a><h2>Arguments</h2><div class="variablelist"><dl class="variablelist"><dt><span class="term"><em class="parameter"><code>mtd</code></em></span></dt><dd><p> 4 mtd info 5 </p></dd><dt><span class="term"><em class="parameter"><code>ofs</code></em></span></dt><dd><p> 6 offset to start unlock from 7 </p></dd><dt><span class="term"><em class="parameter"><code>len</code></em></span></dt><dd><p> 8 length to unlock 9 </p></dd></dl></div></div><div class="refsect1"><a name="idp1102754100"></a><h2>Description</h2><p> 10 This feature is not supported in many NAND parts. 'Micron' NAND parts do 11 have this feature, but it allows only to lock all blocks, not for specified 12 range for block. Implementing 'lock' feature by making use of 'unlock', for 13 now. 14 </p><p> 15 16 Returns lock status. 17</p></div></div><div class="navfooter"><hr><table width="100%" summary="Navigation footer"><tr><td width="40%" align="left"><a accesskey="p" href="API-nand-unlock.html">Prev</a> </td><td width="20%" align="center"><a accesskey="u" href="pubfunctions.html">Up</a></td><td width="40%" align="right"> <a accesskey="n" href="API-nand-scan-ident.html">Next</a></td></tr><tr><td width="40%" align="left" valign="top"><span class="phrase">nand_unlock</span> </td><td width="20%" align="center"><a accesskey="h" href="index.html">Home</a></td><td width="40%" align="right" valign="top"> <span class="phrase">nand_scan_ident</span></td></tr></table></div></body></html> 18