<!-- 
RSS generated by JIRA (9.4.14#940014-sha1:734e6822bbf0d45eff9af51f82432957f73aa32c) at Sat Feb 10 01:50:50 UTC 2024

It is possible to restrict the fields that are returned in this document by specifying the 'field' parameter in your request.
For example, to request only the issue key and summary append 'field=key&field=summary' to the URL of your request.
-->
<rss version="0.92" >
<channel>
    <title>Whamcloud Community JIRA</title>
    <link>https://jira.whamcloud.com</link>
    <description>This file is an XML representation of an issue</description>
    <language>en-us</language>    <build-info>
        <version>9.4.14</version>
        <build-number>940014</build-number>
        <build-date>05-12-2023</build-date>
    </build-info>


<item>
            <title>[LU-5363] kernel update [SLES11 SP3 3.0.101-0.35]</title>
                <link>https://jira.whamcloud.com/browse/LU-5363</link>
                <project id="10000" key="LU">Lustre</project>
                    <description>&lt;p&gt;New kernel version for SLES11 SP3, 3.0.101-0.35. Need to update lustre config and build files.  If upstream fix for loop devices is present need to reeanble sanity test previously skipped.&lt;/p&gt;</description>
                <environment></environment>
        <key id="25633">LU-5363</key>
            <summary>kernel update [SLES11 SP3 3.0.101-0.35]</summary>
                <type id="4" iconUrl="https://jira.whamcloud.com/secure/viewavatar?size=xsmall&amp;avatarId=11310&amp;avatarType=issuetype">Improvement</type>
                                            <priority id="4" iconUrl="https://jira.whamcloud.com/images/icons/priorities/minor.svg">Minor</priority>
                        <status id="5" iconUrl="https://jira.whamcloud.com/images/icons/statuses/resolved.png" description="A resolution has been taken, and it is awaiting verification by reporter. From here issues are either reopened, or are closed.">Resolved</status>
                    <statusCategory id="3" key="done" colorName="success"/>
                                    <resolution id="1">Fixed</resolution>
                                        <assignee username="bogl">Bob Glossman</assignee>
                                    <reporter username="bogl">Bob Glossman</reporter>
                        <labels>
                    </labels>
                <created>Thu, 17 Jul 2014 16:34:28 +0000</created>
                <updated>Mon, 25 Aug 2014 16:55:24 +0000</updated>
                            <resolved>Tue, 19 Aug 2014 01:26:49 +0000</resolved>
                                    <version>Lustre 2.6.0</version>
                                    <fixVersion>Lustre 2.7.0</fixVersion>
                    <fixVersion>Lustre 2.5.3</fixVersion>
                                        <due></due>
                            <votes>0</votes>
                                    <watches>6</watches>
                                                                            <comments>
                            <comment id="89386" author="bogl" created="Thu, 17 Jul 2014 16:44:49 +0000"  >&lt;p&gt;The new update for sles11sp3 has broken the lustre build.  It looks to be due to changes in linux #include files.  example errors:&lt;/p&gt;
&lt;div class=&quot;preformatted panel&quot; style=&quot;border-width: 1px;&quot;&gt;&lt;div class=&quot;preformattedContent panelContent&quot;&gt;
&lt;pre&gt;  CC [M]  /home/bogl/lustre-release/lustre/fid/fid_request.o
In file included from /home/bogl/lustre-release/lustre/include/linux/lustre_compat25.h:44,
                 from /home/bogl/lustre-release/lustre/include/linux/obd_support.h:54,
                 from /home/bogl/lustre-release/lustre/include/obd_support.h:44,
                 from /home/bogl/lustre-release/lustre/include/linux/obd.h:44,
                 from /home/bogl/lustre-release/lustre/include/obd.h:44,
                 from /home/bogl/lustre-release/lustre/fid/fid_request.c:47:
/home/bogl/lustre-release/lustre/include/linux/lustre_patchless_compat.h:100:1: error: &quot;d_count&quot; redefined
In file included from /usr/src/linux-3.0.101-0.35/include/linux/fs.h:396,
                 from /usr/src/linux-3.0.101-0.35/include/linux/pagemap.h:8,
                 from /home/bogl/lustre-release/libcfs/include/libcfs/linux/linux-mem.h:54,
                 from /home/bogl/lustre-release/libcfs/include/libcfs/linux/libcfs.h:52,
                 from /home/bogl/lustre-release/libcfs/include/libcfs/libcfs.h:47,
                 from /home/bogl/lustre-release/lustre/fid/fid_request.c:46:
/usr/src/linux-3.0.101-0.35/include/linux/dcache.h:153:1: error: this is the location of the previous definition
make[8]: *** [/home/bogl/lustre-release/lustre/fid/fid_request.o] Error 1
make[7]: *** [/home/bogl/lustre-release/lustre/fid] Error 2
make[6]: *** [/home/bogl/lustre-release/lustre] Error 2
make[5]: *** [_module_/home/bogl/lustre-release] Error 2
make[4]: *** [sub-make] Error 2
make[3]: *** [all] Error 2
make[3]: Leaving directory `/usr/src/linux-3.0.101-0.35-obj/x86_64/default&apos;
make[2]: *** [modules] Error 2
make[2]: Leaving directory `/home/bogl/lustre-release&apos;
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory `/home/bogl/lustre-release&apos;
make: *** [all] Error 2
&lt;/pre&gt;
&lt;/div&gt;&lt;/div&gt;
&lt;p&gt;This problem appears to be due to new unconditional #defines in kernel &amp;lt;linux/dcache.h&amp;gt; of&lt;/p&gt;

&lt;p&gt;#define d_lock  d_lockref.lock&lt;br/&gt;
#define d_count d_lockref.count&lt;/p&gt;

&lt;p&gt;These conflict with the #define of d_count() (a macro function, not a simple #define) in lustre #include lustre/include/linux/lustre_patchless_compat.h.&lt;/p&gt;

&lt;p&gt;There is already some autoconf for HAVE_D_COUNT, but it looks for an existing d_count() and doesn&apos;t find one in linux #includes.  Not sure how to change things so it operates correctly.  Not sure any distro we still support ever has HAVE_D_COUNT #define&apos;d.&lt;/p&gt;

&lt;p&gt;Think I may need some help solving this build problem.   The kernel update is blocked until I have a working solution.&lt;/p&gt;
</comment>
                            <comment id="89389" author="jeffm" created="Thu, 17 Jul 2014 17:34:34 +0000"  >&lt;p&gt;This is due to the inclusion of lock ref in a performance update. It&apos;s binary compatible with previous releases and defines d_count so previous code that uses d_count directly works as expected. The naming collision is obviously causing problems so we&apos;ll need to work around that a bit.&lt;/p&gt;

&lt;p&gt;This should work, but is untested:&lt;/p&gt;

&lt;div class=&quot;code panel&quot; style=&quot;border-width: 1px;&quot;&gt;&lt;div class=&quot;codeContent panelContent&quot;&gt;
&lt;pre class=&quot;code-java&quot;&gt;diff --git a/lustre/autoconf/lustre-core.m4 b/lustre/autoconf/lustre-core.m4
index 0891fd4..eeba701 100644
--- a/lustre/autoconf/lustre-core.m4
+++ b/lustre/autoconf/lustre-core.m4
@@ -1383,6 +1383,24 @@ d_count, [
 ]) # LC_HAVE_DCOUNT
 
 #
+# LC_HAVE_D_LOCKREF
+#
+# SLES 11 SP3&apos;s 3.0.101-0.35 update adds lockref, but defines a d_count
+# that is different from later kernel versions.
+#
+AC_DEFUN([LC_HAVE_D_LOCKREF], [
+LB_CHECK_COMPILE([&lt;span class=&quot;code-keyword&quot;&gt;if&lt;/span&gt; &apos;d_lockref exists],
+d_lockref, [
+	#include &amp;lt;linux/dcache.h&amp;gt;
+],[
+	struct dentry de;
+	&lt;span class=&quot;code-object&quot;&gt;int&lt;/span&gt; x = de.d_lockref.count;
+],[
+	AC_DEFINE(HAVE_D_LOCKREF, 1, [d_lockref exists])
+])
+]) # LC_HAVE_D_LOCKREF
+
+#
 # LC_OLDSIZE_TRUNCATE_PAGECACHE
 #
 # 3.12 truncate_pagecache without oldsize parameter
@@ -1595,6 +1613,7 @@ AC_DEFUN([LC_PROG_LINUX], [
 	LC_HAVE_DIR_CONTEXT
 	LC_D_COMPARE_5ARGS
 	LC_HAVE_DCOUNT
+	LC_HAVE_D_LOCKREF
 
 	# 3.12
 	LC_OLDSIZE_TRUNCATE_PAGECACHE
diff --git a/lustre/include/linux/lustre_patchless_compat.h b/lustre/include/linux/lustre_patchless_compat.h
index 5b7bab6..d119f75 100644
--- a/lustre/include/linux/lustre_patchless_compat.h
+++ b/lustre/include/linux/lustre_patchless_compat.h
@@ -96,8 +96,11 @@ truncate_complete_page(struct address_space *mapping, struct page *page)
 #ifdef HAVE_DCACHE_LOCK
 #  define dget_dlock(d)			dget_locked(d)
 #  define d_count(d)			atomic_read(&amp;amp;(d)-&amp;gt;d_count)
-#elif !defined(HAVE_D_COUNT)
+#elif !defined(HAVE_D_COUNT) &amp;amp;&amp;amp; !defined(HAVE_D_LOCKREF)
 #  define d_count(d)			((d)-&amp;gt;d_count)
+#elif !define(HAVE_D_COUNT) &amp;amp;&amp;amp; defined(HAVE_D_LOCKREF)
+#undef d_count
+#define d_count(d)			((d)-&amp;gt;d_lockref.count)
 #endif &lt;span class=&quot;code-comment&quot;&gt;/* HAVE_DCACHE_LOCK */&lt;/span&gt;
 
 #ifdef ATTR_OPEN
&lt;/pre&gt;
&lt;/div&gt;&lt;/div&gt;</comment>
                            <comment id="89391" author="bogl" created="Thu, 17 Jul 2014 17:42:14 +0000"  >&lt;p&gt;Jeff, thanks for the suggestion.  Currently working on an alternate approach suggested by Yang Sheng.  doing a wrapper, ll_d_count(), and using autoconf conditionals to translate that correctly for all cases.  Using ll_d_count() instead of d_count() in lustre to avoid name collisions.  If that doesn&apos;t work out I may try your way.&lt;/p&gt;</comment>
                            <comment id="89403" author="bogl" created="Thu, 17 Jul 2014 18:37:22 +0000"  >&lt;p&gt;&lt;a href=&quot;http://review.whamcloud.com/11133&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;http://review.whamcloud.com/11133&lt;/a&gt;&lt;/p&gt;</comment>
                            <comment id="89478" author="bogl" created="Fri, 18 Jul 2014 14:36:37 +0000"  >&lt;p&gt;in b2_5:&lt;br/&gt;
&lt;a href=&quot;http://review.whamcloud.com/11140&quot; class=&quot;external-link&quot; target=&quot;_blank&quot; rel=&quot;nofollow noopener&quot;&gt;http://review.whamcloud.com/11140&lt;/a&gt;&lt;/p&gt;</comment>
                            <comment id="91914" author="pjones" created="Tue, 19 Aug 2014 01:26:49 +0000"  >&lt;p&gt;Landed for 2.7&lt;/p&gt;</comment>
                    </comments>
                    <attachments>
                    </attachments>
                <subtasks>
                    </subtasks>
                <customfields>
                                                                                                                                                                                            <customfield id="customfield_10890" key="com.atlassian.jira.plugins.jira-development-integration-plugin:devsummary">
                        <customfieldname>Development</customfieldname>
                        <customfieldvalues>
                            
                        </customfieldvalues>
                    </customfield>
                                                                                                                                                                                                                                                                                                                                                        <customfield id="customfield_10390" key="com.pyxis.greenhopper.jira:gh-lexo-rank">
                        <customfieldname>Rank</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>1|hzwrp3:</customfieldvalue>

                        </customfieldvalues>
                    </customfield>
                                                                <customfield id="customfield_10090" key="com.pyxis.greenhopper.jira:gh-global-rank">
                        <customfieldname>Rank (Obsolete)</customfieldname>
                        <customfieldvalues>
                            <customfieldvalue>14958</customfieldvalue>
                        </customfieldvalues>
                    </customfield>
                                                                                                                                                                                                                                                                                                                                                                                                                </customfields>
    </item>
</channel>
</rss>