Skip to content

Commit

Permalink
Merge pull request #28 from hannesm/no-mirage-profile
Browse files Browse the repository at this point in the history
remove mirage-profile dependency
  • Loading branch information
hannesm authored Mar 12, 2023
2 parents 7222488 + b8d3ade commit a1b4ca6
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 5 deletions.
2 changes: 0 additions & 2 deletions arp.opam
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,6 @@ doc: "https://mirage.github.io/arp/"
dev-repo: "git+https://github.com/mirage/arp.git"
bug-reports: "https://github.com/mirage/arp/issues"
license: "ISC"

depends: [
"ocaml" {>= "4.06.0"}
"dune" {>= "2.7.0"}
Expand All @@ -17,7 +16,6 @@ depends: [
"mirage-time" {>= "2.0.0"}
"lwt"
"duration"
"mirage-profile" {>= "0.9"}
"ethernet" {>= "3.0.0"}
"bisect_ppx" {dev & >= "2.5.0"}
"mirage-random" {with-test & >= "2.0.0"}
Expand Down
4 changes: 2 additions & 2 deletions mirage/arp.ml
Original file line number Diff line number Diff line change
Expand Up @@ -125,15 +125,15 @@ module Make (Ethernet : Ethernet.S) (Time : Mirage_time.S) = struct

let query t ip =
let merge = function
| None -> MProf.Trace.named_wait "ARP response"
| None -> Lwt.wait ()
| Some a -> a
in
let state, res = Arp_handler.query t.state ip merge in
t.state <- state ;
match res with
| Arp_handler.RequestWait (pkt, (tr, _)) -> output t pkt >>= fun () -> tr
| Arp_handler.Wait (t, _) -> t
| Arp_handler.Mac m -> Lwt.return (Ok m)
| Arp_handler.Mac mac -> Lwt.return (Ok mac)

let connect ethif =
let mac = Ethernet.mac ethif in
Expand Down
2 changes: 1 addition & 1 deletion mirage/dune
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,4 @@
(name arp_mirage)
(public_name arp.mirage)
(wrapped false)
(libraries arp ethernet mirage-time lwt logs duration mirage-profile))
(libraries arp ethernet mirage-time lwt logs duration))

0 comments on commit a1b4ca6

Please sign in to comment.