/******************************************************************************
 * features.c
 *
 * Xen feature flags.
 *
 * Copyright (c) 2006, Ian Campbell, XenSource Inc.
 */
#include <linux/types.h>
#include <linux/cache.h>
#include <linux/export.h>

#include <asm/xen/hypercall.h>

#include <xen/interface/xen.h>
#include <xen/interface/version.h>
#include <xen/features.h>

u8 xen_features[XENFEAT_NR_SUBMAPS * 32] __read_mostly;
EXPORT_SYMBOL_GPL(xen_features);

void xen_setup_features(void)
{
	struct xen_feature_info fi;
	int i, j;

	for (i = 0; i < XENFEAT_NR_SUBMAPS; i++) {
		fi.submap_idx = i;
		if (HYPERVISOR_xen_version(XENVER_get_features, &fi) < 0)
			break;
		for (j = 0; j < 32; j++)
			xen_features[i * 32 + j] = !!(fi.submap & 1<<j);
	}
}
ndex</a> : <a href='/cgit.cgi/linux/net-next.git/'>net-next.git</a></td><td class='form'><form method='get'>
<input type='hidden' name='id' value='d1908f52557b3230fbd63c0429f3b4b748bf2b6d'/><select name='h' onchange='this.form.submit();'>
<option value='emaclite-cleanup'>emaclite-cleanup</option>
<option value='master'>master</option>
<option value='nds-private-remove' selected='selected'>nds-private-remove</option>
<option value='packet-loop-back'>packet-loop-back</option>
<option value='packet-rx-pump-back'>packet-rx-pump-back</option>
</select> <input type='submit' value='switch'/></form></td></tr>
<tr><td class='sub'>net-next plumbings</td><td class='sub right'>Tobias Klauser</td></tr></table>
<table class='tabs'><tr><td>
<a href='/cgit.cgi/linux/net-next.git/?h=nds-private-remove'>summary</a><a href='/cgit.cgi/linux/net-next.git/refs/?h=nds-private-remove&amp;id=d1908f52557b3230fbd63c0429f3b4b748bf2b6d'>refs</a><a class='active' href='/cgit.cgi/linux/net-next.git/log/sound/pci/intel8x0.c?h=nds-private-remove'>log</a><a href='/cgit.cgi/linux/net-next.git/tree/sound/pci/intel8x0.c?h=nds-private-remove&amp;id=d1908f52557b3230fbd63c0429f3b4b748bf2b6d'>tree</a><a href='/cgit.cgi/linux/net-next.git/commit/sound/pci/intel8x0.c?h=nds-private-remove&amp;id=d1908f52557b3230fbd63c0429f3b4b748bf2b6d'>commit</a><a href='/cgit.cgi/linux/net-next.git/diff/sound/pci/intel8x0.c?h=nds-private-remove&amp;id=d1908f52557b3230fbd63c0429f3b4b748bf2b6d'>diff</a></td><td class='form'><form class='right' method='get' action='/cgit.cgi/linux/net-next.git/log/sound/pci/intel8x0.c'>
<input type='hidden' name='h' value='nds-private-remove'/><input type='hidden' name='id' value='d1908f52557b3230fbd63c0429f3b4b748bf2b6d'/><select name='qt'>
<option value='grep'>log msg</option>
<option value='author'>author</option>
<option value='committer'>committer</option>
<option value='range'>range</option>
</select>
<input class='txt' type='search' size='10' name='q' value=''/>
<input type='submit' value='search'/>
</form>
</td></tr></table>
<div class='path'>path: <a href='/cgit.cgi/linux/net-next.git/log/?h=nds-private-remove&amp;id=d1908f52557b3230fbd63c0429f3b4b748bf2b6d'>root</a>/<a href='/cgit.cgi/linux/net-next.git/log/sound?h=nds-private-remove&amp;id=d1908f52557b3230fbd63c0429f3b4b748bf2b6d'>sound</a>/<a href='/cgit.cgi/linux/net-next.git/log/sound/pci?h=nds-private-remove&amp;id=d1908f52557b3230fbd63c0429f3b4b748bf2b6d'>pci</a>/<a href='/cgit.cgi/linux/net-next.git/log/sound/pci/intel8x0.c?h=nds-private-remove&amp;id=d1908f52557b3230fbd63c0429f3b4b748bf2b6d'>intel8x0.c</a></div><div class='content'><table class='list nowrap'><tr class='nohover'><th class='left'>Age</th><th class='left'>Commit message (<a href='/cgit.cgi/linux/net-next.git/log/sound/pci/intel8x0.c?h=nds-private-remove&amp;id=d1908f52557b3230fbd63c0429f3b4b748bf2b6d&amp;showmsg=1'>Expand</a>)</th><th class='left'>Author</th><th class='left'>Files</th><th class='left'>Lines</th></tr>