func (l *cpu9p) FSync() error {
	return l.file.Sync()
}
FSync implements p9.File.FSync.
package main
import (
	"io/ioutil"
	"log"
	"os"
	"path/filepath"
	"syscall"
	"github.com/hugelgupf/p9/fsimpl/templatefs"
	"github.com/hugelgupf/p9/p9"
)
type cpu9p struct {
	p9.DefaultWalkGetAttr
	templatefs.NoopFile
	path string
	file *os.File
}
func (l *cpu9p) Attach() (p9.File, error) {
	return &cpu9p{path: *root}, nil
}
var (
	_ p9.File     = &cpu9p{}
	_ p9.Attacher = &cpu9p{}
)
func (l *cpu9p) info() (p9.QID, os.FileInfo, error) {
	var (
		qid p9.QID
		fi  os.FileInfo
		err error
	)
	if l.file != nil {
		fi, err = l.file.Stat()
	} else {
		fi, err = os.Lstat(l.path)
	}
	if err != nil {
		return qid, nil, err
	}
	qid.Type = p9.ModeFromOS(fi.Mode()).QIDType()
	qid.Path = fi.Sys().(*syscall.Stat_t).Ino
	return qid, fi, nil
}
func (l *cpu9p) Walk(names []string) ([]p9.QID, p9.File, error) {
	var qids []p9.QID
	last := &cpu9p{path: l.path}
	if len(names) == 0 {
		c := &cpu9p{path: last.path}
		qid, fi, err := c.info()
		v("Walk to %v: %v, %v, %v", *c, qid, fi, err)
		if err != nil {
			return nil, nil, err
		}
		qids = append(qids, qid)
		v("Walk: return %v, %v, nil", qids, last)
		return qids, last, nil
	}
	v("Walk: %v", names)
	for _, name := range names {
		c := &cpu9p{path: filepath.Join(last.path, name)}
		qid, fi, err := c.info()
		v("Walk to %v: %v, %v, %v", *c, qid, fi, err)
		if err != nil {
			return nil, nil, err
		}
		qids = append(qids, qid)
		last = c
	}
	v("Walk: return %v, %v, nil", qids, last)
	return qids, last, nil
}