<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>EmbLogic &#187; Sanjeev Khanna</title>
	<atom:link href="https://www.emblogic.com/blog/author/sanjeev-e1/feed/" rel="self" type="application/rss+xml" />
	<link>https://www.emblogic.com/blog</link>
	<description>Embedded System and ARM Training</description>
	<lastBuildDate>Tue, 03 Mar 2020 13:00:06 +0000</lastBuildDate>
	<language>en-US</language>
		<sy:updatePeriod>hourly</sy:updatePeriod>
		<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.9.1</generator>
	<item>
		<title>Undefined error for .ko file !!</title>
		<link>https://www.emblogic.com/blog/10/undefined-error-for-ko-file/</link>
		<comments>https://www.emblogic.com/blog/10/undefined-error-for-ko-file/#comments</comments>
		<pubDate>Thu, 21 Oct 2010 14:10:04 +0000</pubDate>
		<dc:creator><![CDATA[Sanjeev Khanna]]></dc:creator>
				<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false">http://emblogic.org/blog/?p=238</guid>
		<description><![CDATA[scull_follow pointer is defined as: dptr=scull_follow(localptr,item); here localptr is struct scull_dev pointer and item is an integer value giving us 1 less than the total number of qsets required. This is the message i get,when i comment the scull_follow pointer: &#8230; <a href="https://www.emblogic.com/blog/10/undefined-error-for-ko-file/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
				<content:encoded><![CDATA[<p><strong>scull_follow pointer is defined as:</strong></p>
<p>dptr=scull_follow(localptr,item);</p>
<p>here localptr is struct scull_dev pointer and item is an integer value giving us 1 less than the total number of qsets required.</p>
<p><strong>This is the message i get,when i comment the scull_follow pointer</strong>:</p>
<p>make  -C /lib/modules/2.6.32.16-150.fc12.i686.PAE/build M=/project/13oct modules<br />
make[1]: Entering directory `/usr/src/kernels/2.6.32.16-150.fc12.i686.PAE&#8217;<br />
CC [M]  /project/13oct/asng1.o<br />
/project/13oct/asng1.c: In function ‘scull_write’:<br />
/project/13oct/asng1.c:220: warning: ‘dptr’ is used uninitialized in this function<br />
/project/13oct/asng1.c: In function ‘scull_read’:<br />
/project/13oct/asng1.c:180: warning: ‘dptr’ may be used uninitialized in this function<br />
Building modules, stage 2.<br />
MODPOST 1 modules<br />
<strong><em>WARNING: &#8220;__moddi3&#8243; [/project/13oct/asng1.ko] undefined!</em></strong><br />
CC      /project/13oct/asng1.mod.o<br />
LD [M]  /project/13oct/asng1.ko<br />
make[1]: Leaving directory `/usr/src/kernels/2.6.32.16-150.fc12.i686.PAE&#8217;</p>
<p><strong>This is the message i get when i uncomment the scull_follow pointer:</strong></p>
<p>make  -C /lib/modules/2.6.32.16-150.fc12.i686.PAE/build M=/project/13oct modules<br />
make[1]: Entering directory `/usr/src/kernels/2.6.32.16-150.fc12.i686.PAE&#8217;<br />
CC [M]  /project/13oct/asng1.o<br />
Building modules, stage 2.<br />
MODPOST 1 modules<br />
<strong><em>WARNING: &#8220;__moddi3&#8243; [/project/13oct/asng1.ko] undefined!<br />
WARNING: &#8220;__divdi3&#8243; [/project/13oct/asng1.ko] undefined!</em></strong><br />
CC      /project/13oct/asng1.mod.o<br />
LD [M]  /project/13oct/asng1.ko<br />
make[1]: Leaving directory `/usr/src/kernels/2.6.32.16-150.fc12.i686.PAE&#8217;</p>
<p><strong>This is the code for scull_follow:</strong></p>
<p>scull_qset* scull_follow(Scull_dev *localptr,int n)<br />
{</p>
<p>scull_qset *qs;<br />
qs=localptr-&gt;data;     /**/</p>
<p>if(qs==NULL)    /* means ki qs k pass address nai hai */<br />
{<br />
qs=localptr-&gt;data=kmalloc(sizeof(scull_qset),GFP_KERNEL);/* here we r creating a struct scull_qset */<br />
if(qs==NULL)<br />
{<br />
return NULL;<br />
}<br />
memset(qs,&#8221;,sizeof(scull_qset));<br />
}</p>
<p>while(n&gt;0)<br />
{<br />
if(qs-&gt;next==NULL)<br />
{<br />
qs-&gt;next=kmalloc(sizeof(scull_qset),GFP_KERNEL);<br />
if(qs-&gt;next==NULL)<br />
{<br />
return NULL;<br />
}<br />
memset(qs-&gt;next,&#8221;,sizeof(scull_qset));<br />
}<br />
qs=qs-&gt;next;<br />
n&#8211;;<br />
}<br />
return qs;</p>
<p>}</p>
]]></content:encoded>
			<wfw:commentRss>https://www.emblogic.com/blog/10/undefined-error-for-ko-file/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>character driver -&gt; scull open -&gt;container_of</title>
		<link>https://www.emblogic.com/blog/10/character-driver-scull-open-container_of/</link>
		<comments>https://www.emblogic.com/blog/10/character-driver-scull-open-container_of/#comments</comments>
		<pubDate>Mon, 18 Oct 2010 09:06:37 +0000</pubDate>
		<dc:creator><![CDATA[Sanjeev Khanna]]></dc:creator>
				<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false">http://emblogic.org/blog/?p=216</guid>
		<description><![CDATA[the prototype for container_of is as follows: container_of(pointer,container_type,container_field) so what exactly does this return? considering an example, ptr=container_of(inode-&#62;i_cdev,struct scull_dev,cdev) here the pointer &#8216;inode-&#62;i_cdev&#8217; has a field cdev.&#8217;cdev&#8217; is CONTAINED IN struct scull_dev. so ultimately,&#8217;container_of&#8217; takes pointer &#8216;inode-&#62;i_cdev&#8217; to struct scull_dev &#8230; <a href="https://www.emblogic.com/blog/10/character-driver-scull-open-container_of/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
				<content:encoded><![CDATA[<p>the prototype for container_of is as follows:</p>
<p>container_of(pointer,container_type,container_field)</p>
<p>so what exactly does this return?</p>
<p>considering an example,</p>
<p>ptr=container_of(inode-&gt;i_cdev,struct scull_dev,cdev)</p>
<p>here the pointer &#8216;inode-&gt;i_cdev&#8217; has a field cdev.&#8217;cdev&#8217; is CONTAINED IN struct scull_dev.</p>
<p>so ultimately,&#8217;container_of&#8217; takes pointer &#8216;inode-&gt;i_cdev&#8217; to struct scull_dev and returns a pointer containing struct scull_dev.</p>
<p>is it so????</p>
<p>kindly elaborate and add&#8230;&#8230;.</p>
]]></content:encoded>
			<wfw:commentRss>https://www.emblogic.com/blog/10/character-driver-scull-open-container_of/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>scull</title>
		<link>https://www.emblogic.com/blog/09/scull/</link>
		<comments>https://www.emblogic.com/blog/09/scull/#comments</comments>
		<pubDate>Thu, 23 Sep 2010 11:01:14 +0000</pubDate>
		<dc:creator><![CDATA[Sanjeev Khanna]]></dc:creator>
				<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false">http://emblogic.org/blog/?p=125</guid>
		<description><![CDATA[structure of scull is complete.. trying to work on the function recursion part.]]></description>
				<content:encoded><![CDATA[<p>structure of scull is complete..</p>
<p>trying to work on the function recursion part.</p>
]]></content:encoded>
			<wfw:commentRss>https://www.emblogic.com/blog/09/scull/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Client Server using MQ/Semaphores</title>
		<link>https://www.emblogic.com/blog/08/client-server-using-mqsemaphores/</link>
		<comments>https://www.emblogic.com/blog/08/client-server-using-mqsemaphores/#comments</comments>
		<pubDate>Mon, 30 Aug 2010 13:13:48 +0000</pubDate>
		<dc:creator><![CDATA[Sanjeev Khanna]]></dc:creator>
				<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false">http://emblogic.org/blog/?p=101</guid>
		<description><![CDATA[]]></description>
				<content:encoded><![CDATA[]]></content:encoded>
			<wfw:commentRss>https://www.emblogic.com/blog/08/client-server-using-mqsemaphores/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
	</channel>
</rss>
