Add buf support