/* temporary expedient: limit number of entries in discontiguous MDs */
#if PTL_LARGE_MTU
-# define PTL_MD_MAX_IOV 64
+# define PTL_MTU (512<<10)
+# define PTL_MD_MAX_IOV 128
#else
+# define PTL_MTU (64<<10)
# define PTL_MD_MAX_IOV 16
#endif
#ifndef _QSWNAL_H
#define _QSWNAL_H
-#define EXPORT_SYMTAB
+#ifndef EXPORT_SYMTAB
+# define EXPORT_SYMTAB
+#endif
#ifdef PROPRIETARY_ELAN
# include <qsw/kernel.h>
* Performance Tuning defines
* NB no mention of PAGE_SIZE for interoperability
*/
-#if PTL_LARGE_MTU
-# define KQSW_MAXPAYLOAD (256<<10) /* biggest message this NAL will cope with */
-#else
-# define KQSW_MAXPAYLOAD (64<<10) /* biggest message this NAL will cope with */
-#endif
-
+#define KQSW_MAXPAYLOAD PTL_MTU
#define KQSW_SMALLPAYLOAD ((4<<10) - KQSW_HDR_SIZE) /* small/large ep receiver breakpoint */
#define KQSW_TX_MAXCONTIG (1<<10) /* largest payload that gets made contiguous on transmit */
*/
#define DEBUG_PORTAL_ALLOC
-#define EXPORT_SYMTAB
+#ifndef EXPORT_SYMTAB
+# define EXPORT_SYMTAB
+#endif
#include <linux/config.h>
#include <linux/module.h>
#define SOCKNAL_N_SCHED num_online_cpus() /* # socknal schedulers */
-#if PTL_LARGE_MTU
-# define SOCKNAL_MAX_FWD_PAYLOAD (256<<10) /* biggest payload I can forward */
-#else
-# define SOCKNAL_MAX_FWD_PAYLOAD (64<<10) /* biggest payload I can forward */
-#endif
+#define SOCKNAL_MAX_FWD_PAYLOAD PTL_MTU /* biggest payload I can forward */
#define SOCKNAL_NLTXS 128 /* # normal transmit messages */
#define SOCKNAL_NNBLK_LTXS 128 /* # transmit messages reserved if can't block */
int nloops = 0;
int id = sched - ksocknal_data.ksnd_schedulers;
char name[16];
-#if (CONFIG_SMP && CPU_AFFINITY)
-#if (LINUX_VERSION_CODE < KERNEL_VERSION(2,5,0))
- int cpu = cpu_logical_map(id % num_online_cpus());
-#else
-#warning "Take care of architecure specific logical APIC map"
- int cpu = 1; /* Have to change later. */
-#endif /* LINUX_VERSION_CODE */
-
- set_cpus_allowed (current, 1 << cpu);
- id = cpu;
-#endif /* CONFIG_SMP && CPU_AFFINITY */
snprintf (name, sizeof (name),"ksocknald[%d]", id);
kportal_daemonize (name);
kportal_blockallsigs ();
-
+
+#if (CONFIG_SMP && CPU_AFFINITY)
+ if ((cpu_online_map & (1 << id)) != 0)
+ current->cpus_allowed = (1 << id);
+ else
+ CERROR ("Can't set CPU affinity for %s\n", name);
+#endif /* CONFIG_SMP && CPU_AFFINITY */
+
spin_lock_irqsave (&sched->kss_lock, flags);
while (!ksocknal_data.ksnd_shuttingdown) {
*/
#define DEBUG_PORTAL_ALLOC
-#define EXPORT_SYMTAB
+#ifndef EXPORT_SYMTAB
+# define EXPORT_SYMTAB
+#endif
#include <linux/config.h>
#include <linux/module.h>
* Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
*/
-#define EXPORT_SYMTAB
+#ifndef EXPORT_SYMTAB
+# define EXPORT_SYMTAB
+#endif
#include <linux/config.h>
#include <linux/module.h>
* Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
*/
-#define EXPORT_SYMTAB
+#ifndef EXPORT_SYMTAB
+# define EXPORT_SYMTAB
+#endif
#include <linux/config.h>
#include <linux/module.h>
#ifndef _KPTLROUTER_H
#define _KPTLROUTER_H
-#define EXPORT_SYMTAB
+#ifndef EXPORT_SYMTAB
+# define EXPORT_SYMTAB
+#endif
#include <linux/config.h>
#include <linux/module.h>
* Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
*/
-#define EXPORT_SYMTAB
+#ifndef EXPORT_SYMTAB
+# define EXPORT_SYMTAB
+#endif
#define DEBUG_SUBSYSTEM S_LDLM
#ifdef __KERNEL__
*/
#define DEBUG_SUBSYSTEM S_CLASS
-#define EXPORT_SYMTAB
+#ifndef EXPORT_SYMTAB
+# define EXPORT_SYMTAB
+#endif
#include <linux/module.h>
#include <linux/obd_class.h>
* extent tree.
*/
-#define EXPORT_SYMTAB
+#ifndef EXPORT_SYMTAB
+# define EXPORT_SYMTAB
+#endif
#include <linux/version.h>
#include <linux/config.h>
#include <linux/module.h>
* Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
*/
-#define EXPORT_SYMTAB
+#ifndef EXPORT_SYMTAB
+# define EXPORT_SYMTAB
+#endif
#include <linux/version.h>
#include <linux/fs.h>
* Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
*/
-#define EXPORT_SYMTAB
+#ifndef EXPORT_SYMTAB
+# define EXPORT_SYMTAB
+#endif
#define DEBUG_SUBSYSTEM S_OSC
#ifdef __KERNEL__
/* temporary expedient: limit number of entries in discontiguous MDs */
#if PTL_LARGE_MTU
-# define PTL_MD_MAX_IOV 64
+# define PTL_MTU (512<<10)
+# define PTL_MD_MAX_IOV 128
#else
+# define PTL_MTU (64<<10)
# define PTL_MD_MAX_IOV 16
#endif
#ifndef _QSWNAL_H
#define _QSWNAL_H
-#define EXPORT_SYMTAB
+#ifndef EXPORT_SYMTAB
+# define EXPORT_SYMTAB
+#endif
#ifdef PROPRIETARY_ELAN
# include <qsw/kernel.h>
* Performance Tuning defines
* NB no mention of PAGE_SIZE for interoperability
*/
-#if PTL_LARGE_MTU
-# define KQSW_MAXPAYLOAD (256<<10) /* biggest message this NAL will cope with */
-#else
-# define KQSW_MAXPAYLOAD (64<<10) /* biggest message this NAL will cope with */
-#endif
-
+#define KQSW_MAXPAYLOAD PTL_MTU
#define KQSW_SMALLPAYLOAD ((4<<10) - KQSW_HDR_SIZE) /* small/large ep receiver breakpoint */
#define KQSW_TX_MAXCONTIG (1<<10) /* largest payload that gets made contiguous on transmit */
*/
#define DEBUG_PORTAL_ALLOC
-#define EXPORT_SYMTAB
+#ifndef EXPORT_SYMTAB
+# define EXPORT_SYMTAB
+#endif
#include <linux/config.h>
#include <linux/module.h>
#define SOCKNAL_N_SCHED num_online_cpus() /* # socknal schedulers */
-#if PTL_LARGE_MTU
-# define SOCKNAL_MAX_FWD_PAYLOAD (256<<10) /* biggest payload I can forward */
-#else
-# define SOCKNAL_MAX_FWD_PAYLOAD (64<<10) /* biggest payload I can forward */
-#endif
+#define SOCKNAL_MAX_FWD_PAYLOAD PTL_MTU /* biggest payload I can forward */
#define SOCKNAL_NLTXS 128 /* # normal transmit messages */
#define SOCKNAL_NNBLK_LTXS 128 /* # transmit messages reserved if can't block */
int nloops = 0;
int id = sched - ksocknal_data.ksnd_schedulers;
char name[16];
-#if (CONFIG_SMP && CPU_AFFINITY)
-#if (LINUX_VERSION_CODE < KERNEL_VERSION(2,5,0))
- int cpu = cpu_logical_map(id % num_online_cpus());
-#else
-#warning "Take care of architecure specific logical APIC map"
- int cpu = 1; /* Have to change later. */
-#endif /* LINUX_VERSION_CODE */
-
- set_cpus_allowed (current, 1 << cpu);
- id = cpu;
-#endif /* CONFIG_SMP && CPU_AFFINITY */
snprintf (name, sizeof (name),"ksocknald[%d]", id);
kportal_daemonize (name);
kportal_blockallsigs ();
-
+
+#if (CONFIG_SMP && CPU_AFFINITY)
+ if ((cpu_online_map & (1 << id)) != 0)
+ current->cpus_allowed = (1 << id);
+ else
+ CERROR ("Can't set CPU affinity for %s\n", name);
+#endif /* CONFIG_SMP && CPU_AFFINITY */
+
spin_lock_irqsave (&sched->kss_lock, flags);
while (!ksocknal_data.ksnd_shuttingdown) {
*/
#define DEBUG_PORTAL_ALLOC
-#define EXPORT_SYMTAB
+#ifndef EXPORT_SYMTAB
+# define EXPORT_SYMTAB
+#endif
#include <linux/config.h>
#include <linux/module.h>
* Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
*/
-#define EXPORT_SYMTAB
+#ifndef EXPORT_SYMTAB
+# define EXPORT_SYMTAB
+#endif
#include <linux/config.h>
#include <linux/module.h>
* Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
*/
-#define EXPORT_SYMTAB
+#ifndef EXPORT_SYMTAB
+# define EXPORT_SYMTAB
+#endif
#include <linux/config.h>
#include <linux/module.h>
#ifndef _KPTLROUTER_H
#define _KPTLROUTER_H
-#define EXPORT_SYMTAB
+#ifndef EXPORT_SYMTAB
+# define EXPORT_SYMTAB
+#endif
#include <linux/config.h>
#include <linux/module.h>
* Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
*/
-#define EXPORT_SYMTAB
+#ifndef EXPORT_SYMTAB
+# define EXPORT_SYMTAB
+#endif
#define DEBUG_SUBSYSTEM S_RPC
#ifdef __KERNEL__