forked from u-root/u-root
/
multiboot.go
36 lines (27 loc) · 914 Bytes
/
multiboot.go
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
// Copyright 2018 the u-root Authors. All rights reserved
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
package boot
import (
"fmt"
"log"
"github.com/u-root/u-root/pkg/cpio"
)
// multibootImage is a multiboot-formated OSImage.
type multibootImage struct{}
var _ OSImage = &multibootImage{}
func newMultibootImage(a *cpio.Archive) (OSImage, error) {
return nil, fmt.Errorf("multiboot images unimplemented")
}
// ExecutionInfo implements OSImage.ExecutionInfo.
func (multibootImage) ExecutionInfo(log *log.Logger) {
log.Printf("Multiboot images are unsupported")
}
// Execute implements OSImage.Execute.
func (multibootImage) Execute() error {
return fmt.Errorf("multiboot images unimplemented")
}
// Pack implements OSImage.Pack.
func (multibootImage) Pack(sw cpio.RecordWriter) error {
return fmt.Errorf("multiboot images unimplemented")
}